From 625aba3625623e9fd32a1ca4ea23b78ce10d455b Mon Sep 17 00:00:00 2001
From: Laurent Wouters
Date: Wed, 26 Mar 2014 13:51:51 +0100
Subject: Changed viewpoint model to enable the auto-instantiation of model
elements https://bugs.eclipse.org/bugs/show_bug.cgi?id=431139
Signed-off-by: Laurent Wouters
---
.../META-INF/MANIFEST.MF | 9 +-
.../plugin.properties | 5 +
.../ConfigurationItemProviderAdapterFactory.java | 16 +-
.../provider/ElementImportItemProvider.java | 182 ---------------
.../provider/ModelAutoCreateItemProvider.java | 200 ++++++++++++++++
.../provider/ModelRuleItemProvider.java | 40 ----
.../provider/OwningRuleItemProvider.java | 40 ++++
.../provider/PapyrusDiagramItemProvider.java | 7 -
.../META-INF/MANIFEST.MF | 6 +-
.../model/configuration.ecore | 16 +-
.../configuration/ConfigurationFactory.java | 6 +-
.../configuration/ConfigurationPackage.java | 185 ++++++++-------
.../viewpoints/configuration/ElementImport.java | 89 -------
.../viewpoints/configuration/ModelAutoCreate.java | 106 +++++++++
.../infra/viewpoints/configuration/ModelRule.java | 17 --
.../infra/viewpoints/configuration/OwningRule.java | 17 ++
.../viewpoints/configuration/PapyrusDiagram.java | 17 --
.../impl/ConfigurationFactoryImpl.java | 8 +-
.../impl/ConfigurationPackageImpl.java | 72 +++---
.../configuration/impl/ElementImportImpl.java | 228 ------------------
.../configuration/impl/ModelAutoCreateImpl.java | 256 +++++++++++++++++++++
.../configuration/impl/ModelRuleImpl.java | 52 -----
.../configuration/impl/OwningRuleImpl.java | 52 +++++
.../configuration/impl/PapyrusDiagramImpl.java | 37 ---
.../configuration/impl/PathElementImpl.java | 18 --
.../util/ConfigurationAdapterFactory.java | 10 +-
.../configuration/util/ConfigurationSwitch.java | 12 +-
27 files changed, 844 insertions(+), 859 deletions(-)
delete mode 100755 plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/src/org/eclipse/papyrus/infra/viewpoints/configuration/provider/ElementImportItemProvider.java
create mode 100755 plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/src/org/eclipse/papyrus/infra/viewpoints/configuration/provider/ModelAutoCreateItemProvider.java
delete mode 100755 plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/ElementImport.java
create mode 100755 plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/ModelAutoCreate.java
delete mode 100755 plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/ElementImportImpl.java
create mode 100755 plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/ModelAutoCreateImpl.java
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/META-INF/MANIFEST.MF b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/META-INF/MANIFEST.MF
index 6a9401e35f7..25e8553c865 100755
--- a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/META-INF/MANIFEST.MF
+++ b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/META-INF/MANIFEST.MF
@@ -6,18 +6,15 @@ Require-Bundle: org.eclipse.core.runtime,
org.eclipse.papyrus.infra.viewpoints.configuration;bundle-version="1.0.0",
org.eclipse.papyrus.infra.viewpoints.iso42010;bundle-version="1.0.0",
org.eclipse.papyrus.infra.viewpoints.iso42010.edit;bundle-version="1.0.0"
-Export-Package: org.eclipse.papyrus.infra.viewpoints.configuration.pro
- vider
+Export-Package: org.eclipse.papyrus.infra.viewpoints.configuration.provider
Bundle-Vendor: %providerName
Bundle-ActivationPolicy: lazy
Bundle-ClassPath: .
Bundle-Version: 1.0.0.qualifier
Bundle-Localization: plugin
Bundle-Name: %pluginName
-Bundle-Activator: org.eclipse.papyrus.infra.viewpoints.configuration.p
- rovider.ConfigurationEditPlugin$Implementation
+Bundle-Activator: org.eclipse.papyrus.infra.viewpoints.configuration.provider.ConfigurationEditPlugin$Implementation
Bundle-ManifestVersion: 2
-Bundle-SymbolicName: org.eclipse.papyrus.infra.viewpoints.configuratio
- n.edit;singleton:=true
+Bundle-SymbolicName: org.eclipse.papyrus.infra.viewpoints.configuration.edit;singleton:=true
Bundle-RequiredExecutionEnvironment: J2SE-1.5
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/plugin.properties b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/plugin.properties
index 6c33b907a74..387d6eeedde 100755
--- a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/plugin.properties
+++ b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/plugin.properties
@@ -89,3 +89,8 @@ _UI_PapyrusDiagram_imports_feature = Imports
_UI_ElementImport_from_feature = From
_UI_ElementImport_element_feature = Element
_UI_ModelRule_autoSelectPath_feature = Auto Select Path
+_UI_ModelAutoCreate_type = Model Auto Create
+_UI_OwningRule_newModelPath_feature = New Model Path
+_UI_ModelAutoCreate_feature_feature = Feature
+_UI_ModelAutoCreate_origin_feature = Origin
+_UI_ModelAutoCreate_creationType_feature = Creation Type
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/src/org/eclipse/papyrus/infra/viewpoints/configuration/provider/ConfigurationItemProviderAdapterFactory.java b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/src/org/eclipse/papyrus/infra/viewpoints/configuration/provider/ConfigurationItemProviderAdapterFactory.java
index 3414bf305eb..3a52ea4dfda 100755
--- a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/src/org/eclipse/papyrus/infra/viewpoints/configuration/provider/ConfigurationItemProviderAdapterFactory.java
+++ b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/src/org/eclipse/papyrus/infra/viewpoints/configuration/provider/ConfigurationItemProviderAdapterFactory.java
@@ -359,26 +359,26 @@ public class ConfigurationItemProviderAdapterFactory extends ConfigurationAdapte
}
/**
- * This keeps track of the one adapter used for all {@link org.eclipse.papyrus.infra.viewpoints.configuration.ElementImport} instances.
+ * This keeps track of the one adapter used for all {@link org.eclipse.papyrus.infra.viewpoints.configuration.ModelAutoCreate} instances.
*
*
* @generated
*/
- protected ElementImportItemProvider elementImportItemProvider;
+ protected ModelAutoCreateItemProvider modelAutoCreateItemProvider;
/**
- * This creates an adapter for a {@link org.eclipse.papyrus.infra.viewpoints.configuration.ElementImport}.
+ * This creates an adapter for a {@link org.eclipse.papyrus.infra.viewpoints.configuration.ModelAutoCreate}.
*
*
* @generated
*/
@Override
- public Adapter createElementImportAdapter() {
- if (elementImportItemProvider == null) {
- elementImportItemProvider = new ElementImportItemProvider(this);
+ public Adapter createModelAutoCreateAdapter() {
+ if (modelAutoCreateItemProvider == null) {
+ modelAutoCreateItemProvider = new ModelAutoCreateItemProvider(this);
}
- return elementImportItemProvider;
+ return modelAutoCreateItemProvider;
}
/**
@@ -492,7 +492,7 @@ public class ConfigurationItemProviderAdapterFactory extends ConfigurationAdapte
if (paletteRuleItemProvider != null) paletteRuleItemProvider.dispose();
if (pathElementItemProvider != null) pathElementItemProvider.dispose();
if (categoryItemProvider != null) categoryItemProvider.dispose();
- if (elementImportItemProvider != null) elementImportItemProvider.dispose();
+ if (modelAutoCreateItemProvider != null) modelAutoCreateItemProvider.dispose();
}
}
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/src/org/eclipse/papyrus/infra/viewpoints/configuration/provider/ElementImportItemProvider.java b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/src/org/eclipse/papyrus/infra/viewpoints/configuration/provider/ElementImportItemProvider.java
deleted file mode 100755
index 9592e8606c7..00000000000
--- a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/src/org/eclipse/papyrus/infra/viewpoints/configuration/provider/ElementImportItemProvider.java
+++ /dev/null
@@ -1,182 +0,0 @@
-/**
- * Copyright (c) 2013 CEA LIST.
- *
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Laurent Wouters laurent.wouters@cea.fr - Initial API and implementation
- *
- *
- */
-package org.eclipse.papyrus.infra.viewpoints.configuration.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.papyrus.infra.viewpoints.configuration.ConfigurationPackage;
-import org.eclipse.papyrus.infra.viewpoints.configuration.ElementImport;
-
-/**
- * This is the item provider adapter for a {@link org.eclipse.papyrus.infra.viewpoints.configuration.ElementImport} object.
- *
- *
- * @generated
- */
-public class ElementImportItemProvider
- extends ItemProviderAdapter
- implements
- IEditingDomainItemProvider,
- IStructuredItemContentProvider,
- ITreeItemContentProvider,
- IItemLabelProvider,
- IItemPropertySource {
- /**
- * This constructs an instance from a factory and a notifier.
- *
- *
- * @generated
- */
- public ElementImportItemProvider(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);
-
- addFromPropertyDescriptor(object);
- addElementPropertyDescriptor(object);
- }
- return itemPropertyDescriptors;
- }
-
- /**
- * This adds a property descriptor for the From feature.
- *
- *
- * @generated
- */
- protected void addFromPropertyDescriptor(Object object) {
- itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_ElementImport_from_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_ElementImport_from_feature", "_UI_ElementImport_type"),
- ConfigurationPackage.Literals.ELEMENT_IMPORT__FROM,
- true,
- false,
- true,
- null,
- null,
- null));
- }
-
- /**
- * This adds a property descriptor for the Element feature.
- *
- *
- * @generated
- */
- protected void addElementPropertyDescriptor(Object object) {
- itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_ElementImport_element_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_ElementImport_element_feature", "_UI_ElementImport_type"),
- ConfigurationPackage.Literals.ELEMENT_IMPORT__ELEMENT,
- true,
- false,
- true,
- null,
- null,
- null));
- }
-
- /**
- * This returns ElementImport.gif.
- *
- *
- * @generated
- */
- @Override
- public Object getImage(Object object) {
- return overlayImage(object, getResourceLocator().getImage("full/obj16/ElementImport.png"));
- }
-
- /**
- * This returns the label text for the adapted class.
- *
- *
- */
- @Override
- public String getText(Object object) {
- ElementImport ei = (ElementImport) object;
- StringBuilder builder = new StringBuilder("[");
- builder.append(ei.getElement() != null ? ei.getElement().getName() : "?");
- builder.append("] from ");
- builder.append(ei.getFrom() != null ? PapyrusViewItemProvider.getTextFor(ei.getFrom()) : "?");
- return builder.toString();
- }
-
-
- /**
- * 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 ConfigurationEditPlugin.INSTANCE;
- }
-
-}
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/src/org/eclipse/papyrus/infra/viewpoints/configuration/provider/ModelAutoCreateItemProvider.java b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/src/org/eclipse/papyrus/infra/viewpoints/configuration/provider/ModelAutoCreateItemProvider.java
new file mode 100755
index 00000000000..ab883e3b389
--- /dev/null
+++ b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/src/org/eclipse/papyrus/infra/viewpoints/configuration/provider/ModelAutoCreateItemProvider.java
@@ -0,0 +1,200 @@
+/**
+ * Copyright (c) 2013 CEA LIST.
+ *
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Laurent Wouters laurent.wouters@cea.fr - Initial API and implementation
+ *
+ *
+ */
+package org.eclipse.papyrus.infra.viewpoints.configuration.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.papyrus.infra.viewpoints.configuration.ConfigurationPackage;
+
+/**
+ * This is the item provider adapter for a {@link org.eclipse.papyrus.infra.viewpoints.configuration.ModelAutoCreate} object.
+ *
+ *
+ * @generated
+ */
+public class ModelAutoCreateItemProvider
+ extends ItemProviderAdapter
+ implements
+ IEditingDomainItemProvider,
+ IStructuredItemContentProvider,
+ ITreeItemContentProvider,
+ IItemLabelProvider,
+ IItemPropertySource {
+ /**
+ * This constructs an instance from a factory and a notifier.
+ *
+ *
+ * @generated
+ */
+ public ModelAutoCreateItemProvider(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);
+ addOriginPropertyDescriptor(object);
+ addCreationTypePropertyDescriptor(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_ModelAutoCreate_feature_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_ModelAutoCreate_feature_feature", "_UI_ModelAutoCreate_type"),
+ ConfigurationPackage.Literals.MODEL_AUTO_CREATE__FEATURE,
+ true,
+ false,
+ true,
+ null,
+ null,
+ null));
+ }
+
+ /**
+ * This adds a property descriptor for the Origin feature.
+ *
+ *
+ * @generated
+ */
+ protected void addOriginPropertyDescriptor(Object object) {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_ModelAutoCreate_origin_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_ModelAutoCreate_origin_feature", "_UI_ModelAutoCreate_type"),
+ ConfigurationPackage.Literals.MODEL_AUTO_CREATE__ORIGIN,
+ false,
+ false,
+ false,
+ null,
+ null,
+ null));
+ }
+
+ /**
+ * This adds a property descriptor for the Creation Type feature.
+ *
+ *
+ * @generated
+ */
+ protected void addCreationTypePropertyDescriptor(Object object) {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_ModelAutoCreate_creationType_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_ModelAutoCreate_creationType_feature", "_UI_ModelAutoCreate_type"),
+ ConfigurationPackage.Literals.MODEL_AUTO_CREATE__CREATION_TYPE,
+ true,
+ false,
+ true,
+ null,
+ null,
+ null));
+ }
+
+ /**
+ * This returns ModelAutoCreate.gif.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public Object getImage(Object object) {
+ return overlayImage(object, getResourceLocator().getImage("full/obj16/PathElement.png"));
+ }
+
+ /**
+ * This returns the label text for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public String getText(Object object) {
+ return getString("_UI_ModelAutoCreate_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 ConfigurationEditPlugin.INSTANCE;
+ }
+
+}
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/src/org/eclipse/papyrus/infra/viewpoints/configuration/provider/ModelRuleItemProvider.java b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/src/org/eclipse/papyrus/infra/viewpoints/configuration/provider/ModelRuleItemProvider.java
index 450094af358..5a0bf83f021 100755
--- a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/src/org/eclipse/papyrus/infra/viewpoints/configuration/provider/ModelRuleItemProvider.java
+++ b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/src/org/eclipse/papyrus/infra/viewpoints/configuration/provider/ModelRuleItemProvider.java
@@ -19,7 +19,6 @@ 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;
@@ -29,7 +28,6 @@ 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.papyrus.infra.viewpoints.configuration.ConfigurationFactory;
import org.eclipse.papyrus.infra.viewpoints.configuration.ConfigurationPackage;
import org.eclipse.papyrus.infra.viewpoints.configuration.EClassPropertyDescriptor;
import org.eclipse.papyrus.infra.viewpoints.configuration.ModelRule;
@@ -142,36 +140,6 @@ public class ModelRuleItemProvider
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 extends EStructuralFeature> getChildrenFeatures(Object object) {
- if (childrenFeatures == null) {
- super.getChildrenFeatures(object);
- childrenFeatures.add(ConfigurationPackage.Literals.MODEL_RULE__AUTO_SELECT_PATH);
- }
- 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 ModelRule.gif.
*
@@ -224,9 +192,6 @@ public class ModelRuleItemProvider
case ConfigurationPackage.MODEL_RULE__MULTIPLICITY:
fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
return;
- case ConfigurationPackage.MODEL_RULE__AUTO_SELECT_PATH:
- fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
- return;
}
super.notifyChanged(notification);
}
@@ -241,11 +206,6 @@ public class ModelRuleItemProvider
@Override
protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) {
super.collectNewChildDescriptors(newChildDescriptors, object);
-
- newChildDescriptors.add
- (createChildParameter
- (ConfigurationPackage.Literals.MODEL_RULE__AUTO_SELECT_PATH,
- ConfigurationFactory.eINSTANCE.createPathElement()));
}
}
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/src/org/eclipse/papyrus/infra/viewpoints/configuration/provider/OwningRuleItemProvider.java b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/src/org/eclipse/papyrus/infra/viewpoints/configuration/provider/OwningRuleItemProvider.java
index 1748a6c4dd0..780f7709195 100755
--- a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/src/org/eclipse/papyrus/infra/viewpoints/configuration/provider/OwningRuleItemProvider.java
+++ b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/src/org/eclipse/papyrus/infra/viewpoints/configuration/provider/OwningRuleItemProvider.java
@@ -19,6 +19,7 @@ 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;
@@ -28,6 +29,7 @@ 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.papyrus.infra.viewpoints.configuration.ConfigurationFactory;
import org.eclipse.papyrus.infra.viewpoints.configuration.ConfigurationPackage;
import org.eclipse.papyrus.infra.viewpoints.configuration.EClassPropertyDescriptor;
import org.eclipse.papyrus.infra.viewpoints.configuration.OwningRule;
@@ -139,6 +141,36 @@ public class OwningRuleItemProvider
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 extends EStructuralFeature> getChildrenFeatures(Object object) {
+ if (childrenFeatures == null) {
+ super.getChildrenFeatures(object);
+ childrenFeatures.add(ConfigurationPackage.Literals.OWNING_RULE__NEW_MODEL_PATH);
+ }
+ 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 OwningRule.gif.
*
@@ -191,6 +223,9 @@ public class OwningRuleItemProvider
case ConfigurationPackage.OWNING_RULE__MULTIPLICITY:
fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
return;
+ case ConfigurationPackage.OWNING_RULE__NEW_MODEL_PATH:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
+ return;
}
super.notifyChanged(notification);
}
@@ -205,6 +240,11 @@ public class OwningRuleItemProvider
@Override
protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) {
super.collectNewChildDescriptors(newChildDescriptors, object);
+
+ newChildDescriptors.add
+ (createChildParameter
+ (ConfigurationPackage.Literals.OWNING_RULE__NEW_MODEL_PATH,
+ ConfigurationFactory.eINSTANCE.createModelAutoCreate()));
}
}
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/src/org/eclipse/papyrus/infra/viewpoints/configuration/provider/PapyrusDiagramItemProvider.java b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/src/org/eclipse/papyrus/infra/viewpoints/configuration/provider/PapyrusDiagramItemProvider.java
index 8263e4d0dd1..8ceb433fd7c 100755
--- a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/src/org/eclipse/papyrus/infra/viewpoints/configuration/provider/PapyrusDiagramItemProvider.java
+++ b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration.edit/src/org/eclipse/papyrus/infra/viewpoints/configuration/provider/PapyrusDiagramItemProvider.java
@@ -132,7 +132,6 @@ public class PapyrusDiagramItemProvider
super.getChildrenFeatures(object);
childrenFeatures.add(ConfigurationPackage.Literals.PAPYRUS_DIAGRAM__CHILD_RULES);
childrenFeatures.add(ConfigurationPackage.Literals.PAPYRUS_DIAGRAM__PALETTE_RULES);
- childrenFeatures.add(ConfigurationPackage.Literals.PAPYRUS_DIAGRAM__IMPORTS);
}
return childrenFeatures;
}
@@ -189,7 +188,6 @@ public class PapyrusDiagramItemProvider
return;
case ConfigurationPackage.PAPYRUS_DIAGRAM__CHILD_RULES:
case ConfigurationPackage.PAPYRUS_DIAGRAM__PALETTE_RULES:
- case ConfigurationPackage.PAPYRUS_DIAGRAM__IMPORTS:
fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
return;
}
@@ -216,11 +214,6 @@ public class PapyrusDiagramItemProvider
(createChildParameter
(ConfigurationPackage.Literals.PAPYRUS_DIAGRAM__PALETTE_RULES,
ConfigurationFactory.eINSTANCE.createPaletteRule()));
-
- newChildDescriptors.add
- (createChildParameter
- (ConfigurationPackage.Literals.PAPYRUS_DIAGRAM__IMPORTS,
- ConfigurationFactory.eINSTANCE.createElementImport()));
}
}
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/META-INF/MANIFEST.MF b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/META-INF/MANIFEST.MF
index cc49df1ed96..c08080d9874 100755
--- a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/META-INF/MANIFEST.MF
+++ b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/META-INF/MANIFEST.MF
@@ -16,10 +16,8 @@ Bundle-ClassPath: .
Bundle-Version: 1.0.0.qualifier
Bundle-Localization: plugin
Bundle-Name: %pluginName
-Bundle-Activator: org.eclipse.papyrus.infra.viewpoints.configuration.A
- ctivator
+Bundle-Activator: org.eclipse.papyrus.infra.viewpoints.configuration.Activator
Bundle-ManifestVersion: 2
-Bundle-SymbolicName: org.eclipse.papyrus.infra.viewpoints.configuratio
- n;singleton:=true
+Bundle-SymbolicName: org.eclipse.papyrus.infra.viewpoints.configuration;singleton:=true
Bundle-RequiredExecutionEnvironment: J2SE-1.5
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/model/configuration.ecore b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/model/configuration.ecore
index fa114a399eb..68809247223 100755
--- a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/model/configuration.ecore
+++ b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/model/configuration.ecore
@@ -50,8 +50,6 @@
-
@@ -68,8 +66,6 @@
eType="ecore:EClass http://www.eclipse.org/emf/2002/Ecore#//EClass"/>
-
@@ -77,6 +73,8 @@
eType="ecore:EClass http://www.eclipse.org/emf/2002/Ecore#//EClass"/>
+
@@ -102,9 +100,13 @@
-
-
-
+
+
+
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/ConfigurationFactory.java b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/ConfigurationFactory.java
index 3a6909c1508..5ffd4e9cbd3 100755
--- a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/ConfigurationFactory.java
+++ b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/ConfigurationFactory.java
@@ -141,13 +141,13 @@ public interface ConfigurationFactory extends EFactory {
Category createCategory();
/**
- * Returns a new object of class 'Element Import '.
+ * Returns a new object of class 'Model Auto Create '.
*
*
- * @return a new object of class 'Element Import '.
+ * @return a new object of class 'Model Auto Create '.
* @generated
*/
- ElementImport createElementImport();
+ ModelAutoCreate createModelAutoCreate();
/**
* Returns the package supported by this factory.
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/ConfigurationPackage.java b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/ConfigurationPackage.java
index 25d0f1d2ee7..6a415ddccd7 100755
--- a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/ConfigurationPackage.java
+++ b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/ConfigurationPackage.java
@@ -514,15 +514,6 @@ public interface ConfigurationPackage extends EPackage {
*/
int PAPYRUS_DIAGRAM__PALETTE_RULES = PAPYRUS_VIEW_FEATURE_COUNT + 3;
- /**
- * The feature id for the 'Imports ' containment reference list.
- *
- *
- * @generated
- * @ordered
- */
- int PAPYRUS_DIAGRAM__IMPORTS = PAPYRUS_VIEW_FEATURE_COUNT + 4;
-
/**
* The number of structural features of the 'Papyrus Diagram ' class.
*
@@ -530,7 +521,7 @@ public interface ConfigurationPackage extends EPackage {
* @generated
* @ordered
*/
- int PAPYRUS_DIAGRAM_FEATURE_COUNT = PAPYRUS_VIEW_FEATURE_COUNT + 5;
+ int PAPYRUS_DIAGRAM_FEATURE_COUNT = PAPYRUS_VIEW_FEATURE_COUNT + 4;
/**
* The number of operations of the 'Papyrus Diagram ' class.
@@ -887,15 +878,6 @@ public interface ConfigurationPackage extends EPackage {
*/
int MODEL_RULE__MULTIPLICITY = RULE_FEATURE_COUNT + 2;
- /**
- * The feature id for the 'Auto Select Path ' containment reference list.
- *
- *
- * @generated
- * @ordered
- */
- int MODEL_RULE__AUTO_SELECT_PATH = RULE_FEATURE_COUNT + 3;
-
/**
* The number of structural features of the 'Model Rule ' class.
*
@@ -903,7 +885,7 @@ public interface ConfigurationPackage extends EPackage {
* @generated
* @ordered
*/
- int MODEL_RULE_FEATURE_COUNT = RULE_FEATURE_COUNT + 4;
+ int MODEL_RULE_FEATURE_COUNT = RULE_FEATURE_COUNT + 3;
/**
* The number of operations of the 'Model Rule ' class.
@@ -960,6 +942,15 @@ public interface ConfigurationPackage extends EPackage {
*/
int OWNING_RULE__MULTIPLICITY = RULE_FEATURE_COUNT + 2;
+ /**
+ * The feature id for the 'New Model Path ' containment reference list.
+ *
+ *
+ * @generated
+ * @ordered
+ */
+ int OWNING_RULE__NEW_MODEL_PATH = RULE_FEATURE_COUNT + 3;
+
/**
* The number of structural features of the 'Owning Rule ' class.
*
@@ -967,7 +958,7 @@ public interface ConfigurationPackage extends EPackage {
* @generated
* @ordered
*/
- int OWNING_RULE_FEATURE_COUNT = RULE_FEATURE_COUNT + 3;
+ int OWNING_RULE_FEATURE_COUNT = RULE_FEATURE_COUNT + 4;
/**
* The number of operations of the 'Owning Rule ' class.
@@ -1192,51 +1183,59 @@ public interface ConfigurationPackage extends EPackage {
/**
- * The meta object id for the '{@link org.eclipse.papyrus.infra.viewpoints.configuration.impl.ElementImportImpl Element Import }' class.
+ * The meta object id for the '{@link org.eclipse.papyrus.infra.viewpoints.configuration.impl.ModelAutoCreateImpl Model Auto Create }' class.
*
*
- * @see org.eclipse.papyrus.infra.viewpoints.configuration.impl.ElementImportImpl
- * @see org.eclipse.papyrus.infra.viewpoints.configuration.impl.ConfigurationPackageImpl#getElementImport()
+ * @see org.eclipse.papyrus.infra.viewpoints.configuration.impl.ModelAutoCreateImpl
+ * @see org.eclipse.papyrus.infra.viewpoints.configuration.impl.ConfigurationPackageImpl#getModelAutoCreate()
* @generated
*/
- int ELEMENT_IMPORT = 13;
+ int MODEL_AUTO_CREATE = 13;
/**
- * The feature id for the 'From ' reference.
+ * The feature id for the 'Feature ' reference.
*
*
* @generated
* @ordered
*/
- int ELEMENT_IMPORT__FROM = 0;
+ int MODEL_AUTO_CREATE__FEATURE = 0;
/**
- * The feature id for the 'Element ' reference.
+ * The feature id for the 'Origin ' reference.
*
*
* @generated
* @ordered
*/
- int ELEMENT_IMPORT__ELEMENT = 1;
+ int MODEL_AUTO_CREATE__ORIGIN = 1;
/**
- * The number of structural features of the 'Element Import ' class.
+ * The feature id for the 'Creation Type ' reference.
*
*
* @generated
* @ordered
*/
- int ELEMENT_IMPORT_FEATURE_COUNT = 2;
+ int MODEL_AUTO_CREATE__CREATION_TYPE = 2;
/**
- * The number of operations of the 'Element Import ' class.
+ * The number of structural features of the 'Model Auto Create ' class.
*
*
* @generated
* @ordered
*/
- int ELEMENT_IMPORT_OPERATION_COUNT = 0;
+ int MODEL_AUTO_CREATE_FEATURE_COUNT = 3;
+ /**
+ * The number of operations of the 'Model Auto Create ' class.
+ *
+ *
+ * @generated
+ * @ordered
+ */
+ int MODEL_AUTO_CREATE_OPERATION_COUNT = 0;
/**
* Returns the meta object for class '{@link org.eclipse.papyrus.infra.viewpoints.configuration.PapyrusConfiguration Papyrus Configuration }'.
@@ -1443,17 +1442,6 @@ public interface ConfigurationPackage extends EPackage {
*/
EReference getPapyrusDiagram_PaletteRules();
- /**
- * Returns the meta object for the containment reference list '{@link org.eclipse.papyrus.infra.viewpoints.configuration.PapyrusDiagram#getImports Imports }'.
- *
- *
- * @return the meta object for the containment reference list 'Imports '.
- * @see org.eclipse.papyrus.infra.viewpoints.configuration.PapyrusDiagram#getImports()
- * @see #getPapyrusDiagram()
- * @generated
- */
- EReference getPapyrusDiagram_Imports();
-
/**
* Returns the meta object for class '{@link org.eclipse.papyrus.infra.viewpoints.configuration.PapyrusSyncTable Papyrus Sync Table }'.
*
@@ -1528,17 +1516,6 @@ public interface ConfigurationPackage extends EPackage {
*/
EAttribute getModelRule_Multiplicity();
- /**
- * Returns the meta object for the containment reference list '{@link org.eclipse.papyrus.infra.viewpoints.configuration.ModelRule#getAutoSelectPath Auto Select Path }'.
- *
- *
- * @return the meta object for the containment reference list 'Auto Select Path '.
- * @see org.eclipse.papyrus.infra.viewpoints.configuration.ModelRule#getAutoSelectPath()
- * @see #getModelRule()
- * @generated
- */
- EReference getModelRule_AutoSelectPath();
-
/**
* Returns the meta object for class '{@link org.eclipse.papyrus.infra.viewpoints.configuration.OwningRule Owning Rule }'.
*
@@ -1582,6 +1559,17 @@ public interface ConfigurationPackage extends EPackage {
*/
EAttribute getOwningRule_Multiplicity();
+ /**
+ * Returns the meta object for the containment reference list '{@link org.eclipse.papyrus.infra.viewpoints.configuration.OwningRule#getNewModelPath New Model Path }'.
+ *
+ *
+ * @return the meta object for the containment reference list 'New Model Path '.
+ * @see org.eclipse.papyrus.infra.viewpoints.configuration.OwningRule#getNewModelPath()
+ * @see #getOwningRule()
+ * @generated
+ */
+ EReference getOwningRule_NewModelPath();
+
/**
* Returns the meta object for class '{@link org.eclipse.papyrus.infra.viewpoints.configuration.ChildRule Child Rule }'.
*
@@ -1743,36 +1731,47 @@ public interface ConfigurationPackage extends EPackage {
EAttribute getCategory_Name();
/**
- * Returns the meta object for class '{@link org.eclipse.papyrus.infra.viewpoints.configuration.ElementImport Element Import }'.
+ * Returns the meta object for class '{@link org.eclipse.papyrus.infra.viewpoints.configuration.ModelAutoCreate Model Auto Create }'.
*
*
- * @return the meta object for class 'Element Import '.
- * @see org.eclipse.papyrus.infra.viewpoints.configuration.ElementImport
+ * @return the meta object for class 'Model Auto Create '.
+ * @see org.eclipse.papyrus.infra.viewpoints.configuration.ModelAutoCreate
* @generated
*/
- EClass getElementImport();
+ EClass getModelAutoCreate();
/**
- * Returns the meta object for the reference '{@link org.eclipse.papyrus.infra.viewpoints.configuration.ElementImport#getFrom From }'.
+ * Returns the meta object for the reference '{@link org.eclipse.papyrus.infra.viewpoints.configuration.ModelAutoCreate#getFeature Feature }'.
*
*
- * @return the meta object for the reference 'From '.
- * @see org.eclipse.papyrus.infra.viewpoints.configuration.ElementImport#getFrom()
- * @see #getElementImport()
+ * @return the meta object for the reference 'Feature '.
+ * @see org.eclipse.papyrus.infra.viewpoints.configuration.ModelAutoCreate#getFeature()
+ * @see #getModelAutoCreate()
* @generated
*/
- EReference getElementImport_From();
+ EReference getModelAutoCreate_Feature();
/**
- * Returns the meta object for the reference '{@link org.eclipse.papyrus.infra.viewpoints.configuration.ElementImport#getElement Element }'.
+ * Returns the meta object for the reference '{@link org.eclipse.papyrus.infra.viewpoints.configuration.ModelAutoCreate#getOrigin Origin }'.
*
*
- * @return the meta object for the reference 'Element '.
- * @see org.eclipse.papyrus.infra.viewpoints.configuration.ElementImport#getElement()
- * @see #getElementImport()
+ * @return the meta object for the reference 'Origin '.
+ * @see org.eclipse.papyrus.infra.viewpoints.configuration.ModelAutoCreate#getOrigin()
+ * @see #getModelAutoCreate()
+ * @generated
+ */
+ EReference getModelAutoCreate_Origin();
+
+ /**
+ * Returns the meta object for the reference '{@link org.eclipse.papyrus.infra.viewpoints.configuration.ModelAutoCreate#getCreationType Creation Type }'.
+ *
+ *
+ * @return the meta object for the reference 'Creation Type '.
+ * @see org.eclipse.papyrus.infra.viewpoints.configuration.ModelAutoCreate#getCreationType()
+ * @see #getModelAutoCreate()
* @generated
*/
- EReference getElementImport_Element();
+ EReference getModelAutoCreate_CreationType();
/**
* Returns the factory that creates the instances of the model.
@@ -1957,14 +1956,6 @@ public interface ConfigurationPackage extends EPackage {
*/
EReference PAPYRUS_DIAGRAM__PALETTE_RULES = eINSTANCE.getPapyrusDiagram_PaletteRules();
- /**
- * The meta object literal for the 'Imports ' containment reference list feature.
- *
- *
- * @generated
- */
- EReference PAPYRUS_DIAGRAM__IMPORTS = eINSTANCE.getPapyrusDiagram_Imports();
-
/**
* The meta object literal for the '{@link org.eclipse.papyrus.infra.viewpoints.configuration.impl.PapyrusSyncTableImpl Papyrus Sync Table }' class.
*
@@ -2027,14 +2018,6 @@ public interface ConfigurationPackage extends EPackage {
*/
EAttribute MODEL_RULE__MULTIPLICITY = eINSTANCE.getModelRule_Multiplicity();
- /**
- * The meta object literal for the 'Auto Select Path ' containment reference list feature.
- *
- *
- * @generated
- */
- EReference MODEL_RULE__AUTO_SELECT_PATH = eINSTANCE.getModelRule_AutoSelectPath();
-
/**
* The meta object literal for the '{@link org.eclipse.papyrus.infra.viewpoints.configuration.impl.OwningRuleImpl Owning Rule }' class.
*
@@ -2069,6 +2052,14 @@ public interface ConfigurationPackage extends EPackage {
*/
EAttribute OWNING_RULE__MULTIPLICITY = eINSTANCE.getOwningRule_Multiplicity();
+ /**
+ * The meta object literal for the 'New Model Path ' containment reference list feature.
+ *
+ *
+ * @generated
+ */
+ EReference OWNING_RULE__NEW_MODEL_PATH = eINSTANCE.getOwningRule_NewModelPath();
+
/**
* The meta object literal for the '{@link org.eclipse.papyrus.infra.viewpoints.configuration.impl.ChildRuleImpl Child Rule }' class.
*
@@ -2200,30 +2191,38 @@ public interface ConfigurationPackage extends EPackage {
EAttribute CATEGORY__NAME = eINSTANCE.getCategory_Name();
/**
- * The meta object literal for the '{@link org.eclipse.papyrus.infra.viewpoints.configuration.impl.ElementImportImpl Element Import }' class.
+ * The meta object literal for the '{@link org.eclipse.papyrus.infra.viewpoints.configuration.impl.ModelAutoCreateImpl Model Auto Create }' class.
*
*
- * @see org.eclipse.papyrus.infra.viewpoints.configuration.impl.ElementImportImpl
- * @see org.eclipse.papyrus.infra.viewpoints.configuration.impl.ConfigurationPackageImpl#getElementImport()
+ * @see org.eclipse.papyrus.infra.viewpoints.configuration.impl.ModelAutoCreateImpl
+ * @see org.eclipse.papyrus.infra.viewpoints.configuration.impl.ConfigurationPackageImpl#getModelAutoCreate()
* @generated
*/
- EClass ELEMENT_IMPORT = eINSTANCE.getElementImport();
+ EClass MODEL_AUTO_CREATE = eINSTANCE.getModelAutoCreate();
/**
- * The meta object literal for the 'From ' reference feature.
+ * The meta object literal for the 'Feature ' reference feature.
*
*
* @generated
*/
- EReference ELEMENT_IMPORT__FROM = eINSTANCE.getElementImport_From();
+ EReference MODEL_AUTO_CREATE__FEATURE = eINSTANCE.getModelAutoCreate_Feature();
/**
- * The meta object literal for the 'Element ' reference feature.
+ * The meta object literal for the 'Origin ' reference feature.
+ *
+ *
+ * @generated
+ */
+ EReference MODEL_AUTO_CREATE__ORIGIN = eINSTANCE.getModelAutoCreate_Origin();
+
+ /**
+ * The meta object literal for the 'Creation Type ' reference feature.
*
*
* @generated
*/
- EReference ELEMENT_IMPORT__ELEMENT = eINSTANCE.getElementImport_Element();
+ EReference MODEL_AUTO_CREATE__CREATION_TYPE = eINSTANCE.getModelAutoCreate_CreationType();
}
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/ElementImport.java b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/ElementImport.java
deleted file mode 100755
index f4a7feb3f20..00000000000
--- a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/ElementImport.java
+++ /dev/null
@@ -1,89 +0,0 @@
-/**
- * Copyright (c) 2013 CEA LIST.
- *
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Laurent Wouters laurent.wouters@cea.fr - Initial API and implementation
- *
- *
- */
-package org.eclipse.papyrus.infra.viewpoints.configuration;
-
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EObject;
-
-/**
- *
- * A representation of the model object 'Element Import '.
- *
- *
- *
- * The following features are supported:
- *
- * {@link org.eclipse.papyrus.infra.viewpoints.configuration.ElementImport#getFrom From }
- * {@link org.eclipse.papyrus.infra.viewpoints.configuration.ElementImport#getElement Element }
- *
- *
- *
- * @see org.eclipse.papyrus.infra.viewpoints.configuration.ConfigurationPackage#getElementImport()
- * @model
- * @generated
- */
-public interface ElementImport extends EObject {
- /**
- * Returns the value of the 'From ' reference.
- *
- *
- * If the meaning of the 'From ' reference isn't clear,
- * there really should be more of a description here...
- *
- *
- * @return the value of the 'From ' reference.
- * @see #setFrom(PapyrusDiagram)
- * @see org.eclipse.papyrus.infra.viewpoints.configuration.ConfigurationPackage#getElementImport_From()
- * @model required="true"
- * @generated
- */
- PapyrusDiagram getFrom();
-
- /**
- * Sets the value of the '{@link org.eclipse.papyrus.infra.viewpoints.configuration.ElementImport#getFrom From }' reference.
- *
- *
- * @param value the new value of the 'From ' reference.
- * @see #getFrom()
- * @generated
- */
- void setFrom(PapyrusDiagram value);
-
- /**
- * Returns the value of the 'Element ' reference.
- *
- *
- * If the meaning of the 'Element ' reference isn't clear,
- * there really should be more of a description here...
- *
- *
- * @return the value of the 'Element ' reference.
- * @see #setElement(EClass)
- * @see org.eclipse.papyrus.infra.viewpoints.configuration.ConfigurationPackage#getElementImport_Element()
- * @model required="true"
- * @generated
- */
- EClass getElement();
-
- /**
- * Sets the value of the '{@link org.eclipse.papyrus.infra.viewpoints.configuration.ElementImport#getElement Element }' reference.
- *
- *
- * @param value the new value of the 'Element ' reference.
- * @see #getElement()
- * @generated
- */
- void setElement(EClass value);
-
-} // ElementImport
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/ModelAutoCreate.java b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/ModelAutoCreate.java
new file mode 100755
index 00000000000..6880563fbe1
--- /dev/null
+++ b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/ModelAutoCreate.java
@@ -0,0 +1,106 @@
+/**
+ * Copyright (c) 2013 CEA LIST.
+ *
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Laurent Wouters laurent.wouters@cea.fr - Initial API and implementation
+ *
+ *
+ */
+package org.eclipse.papyrus.infra.viewpoints.configuration;
+
+import org.eclipse.emf.ecore.EClass;
+import org.eclipse.emf.ecore.EObject;
+import org.eclipse.emf.ecore.EReference;
+
+/**
+ *
+ * A representation of the model object 'Model Auto Create '.
+ *
+ *
+ *
+ * The following features are supported:
+ *
+ * {@link org.eclipse.papyrus.infra.viewpoints.configuration.ModelAutoCreate#getFeature Feature }
+ * {@link org.eclipse.papyrus.infra.viewpoints.configuration.ModelAutoCreate#getOrigin Origin }
+ * {@link org.eclipse.papyrus.infra.viewpoints.configuration.ModelAutoCreate#getCreationType Creation Type }
+ *
+ *
+ *
+ * @see org.eclipse.papyrus.infra.viewpoints.configuration.ConfigurationPackage#getModelAutoCreate()
+ * @model
+ * @generated
+ */
+public interface ModelAutoCreate extends EObject {
+ /**
+ * 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.papyrus.infra.viewpoints.configuration.ConfigurationPackage#getModelAutoCreate_Feature()
+ * @model required="true"
+ * @generated
+ */
+ EReference getFeature();
+
+ /**
+ * Sets the value of the '{@link org.eclipse.papyrus.infra.viewpoints.configuration.ModelAutoCreate#getFeature Feature }' reference.
+ *
+ *
+ * @param value the new value of the 'Feature ' reference.
+ * @see #getFeature()
+ * @generated
+ */
+ void setFeature(EReference value);
+
+ /**
+ * Returns the value of the 'Origin ' reference.
+ *
+ *
+ * If the meaning of the 'Origin ' reference isn't clear,
+ * there really should be more of a description here...
+ *
+ *
+ * @return the value of the 'Origin ' reference.
+ * @see org.eclipse.papyrus.infra.viewpoints.configuration.ConfigurationPackage#getModelAutoCreate_Origin()
+ * @model required="true" transient="true" changeable="false" volatile="true" derived="true"
+ * @generated
+ */
+ EClass getOrigin();
+
+ /**
+ * Returns the value of the 'Creation Type ' reference.
+ *
+ *
+ * If the meaning of the 'Creation Type ' reference isn't clear,
+ * there really should be more of a description here...
+ *
+ *
+ * @return the value of the 'Creation Type ' reference.
+ * @see #setCreationType(EClass)
+ * @see org.eclipse.papyrus.infra.viewpoints.configuration.ConfigurationPackage#getModelAutoCreate_CreationType()
+ * @model required="true"
+ * @generated
+ */
+ EClass getCreationType();
+
+ /**
+ * Sets the value of the '{@link org.eclipse.papyrus.infra.viewpoints.configuration.ModelAutoCreate#getCreationType Creation Type }' reference.
+ *
+ *
+ * @param value the new value of the 'Creation Type ' reference.
+ * @see #getCreationType()
+ * @generated
+ */
+ void setCreationType(EClass value);
+
+} // ModelAutoCreate
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/ModelRule.java b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/ModelRule.java
index e4e1607b709..ab2d7fa18ed 100755
--- a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/ModelRule.java
+++ b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/ModelRule.java
@@ -27,7 +27,6 @@ import org.eclipse.emf.ecore.EClass;
* {@link org.eclipse.papyrus.infra.viewpoints.configuration.ModelRule#getElement Element }
* {@link org.eclipse.papyrus.infra.viewpoints.configuration.ModelRule#getStereotypes Stereotypes }
* {@link org.eclipse.papyrus.infra.viewpoints.configuration.ModelRule#getMultiplicity Multiplicity }
- * {@link org.eclipse.papyrus.infra.viewpoints.configuration.ModelRule#getAutoSelectPath Auto Select Path }
*
*
*
@@ -105,20 +104,4 @@ public interface ModelRule extends Rule {
*/
void setMultiplicity(int value);
- /**
- * Returns the value of the 'Auto Select Path ' containment reference list.
- * The list contents are of type {@link org.eclipse.papyrus.infra.viewpoints.configuration.PathElement}.
- *
- *
- * If the meaning of the 'Auto Select Path ' containment reference list isn't clear,
- * there really should be more of a description here...
- *
- *
- * @return the value of the 'Auto Select Path ' containment reference list.
- * @see org.eclipse.papyrus.infra.viewpoints.configuration.ConfigurationPackage#getModelRule_AutoSelectPath()
- * @model containment="true"
- * @generated
- */
- EList getAutoSelectPath();
-
} // ModelRule
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/OwningRule.java b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/OwningRule.java
index ae4140cbdbf..d6ab0dc0f4d 100755
--- a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/OwningRule.java
+++ b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/OwningRule.java
@@ -27,6 +27,7 @@ import org.eclipse.emf.ecore.EClass;
* {@link org.eclipse.papyrus.infra.viewpoints.configuration.OwningRule#getElement Element }
* {@link org.eclipse.papyrus.infra.viewpoints.configuration.OwningRule#getStereotypes Stereotypes }
* {@link org.eclipse.papyrus.infra.viewpoints.configuration.OwningRule#getMultiplicity Multiplicity }
+ * {@link org.eclipse.papyrus.infra.viewpoints.configuration.OwningRule#getNewModelPath New Model Path }
*
*
*
@@ -104,4 +105,20 @@ public interface OwningRule extends Rule {
*/
void setMultiplicity(int value);
+ /**
+ * Returns the value of the 'New Model Path ' containment reference list.
+ * The list contents are of type {@link org.eclipse.papyrus.infra.viewpoints.configuration.ModelAutoCreate}.
+ *
+ *
+ * If the meaning of the 'New Model Path ' reference list isn't clear,
+ * there really should be more of a description here...
+ *
+ *
+ * @return the value of the 'New Model Path ' containment reference list.
+ * @see org.eclipse.papyrus.infra.viewpoints.configuration.ConfigurationPackage#getOwningRule_NewModelPath()
+ * @model containment="true"
+ * @generated
+ */
+ EList getNewModelPath();
+
} // OwningRule
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/PapyrusDiagram.java b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/PapyrusDiagram.java
index 7f01343501b..621d85a9572 100755
--- a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/PapyrusDiagram.java
+++ b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/PapyrusDiagram.java
@@ -27,7 +27,6 @@ import org.eclipse.emf.common.util.EList;
* {@link org.eclipse.papyrus.infra.viewpoints.configuration.PapyrusDiagram#getCustomStyle Custom Style }
* {@link org.eclipse.papyrus.infra.viewpoints.configuration.PapyrusDiagram#getChildRules Child Rules }
* {@link org.eclipse.papyrus.infra.viewpoints.configuration.PapyrusDiagram#getPaletteRules Palette Rules }
- * {@link org.eclipse.papyrus.infra.viewpoints.configuration.PapyrusDiagram#getImports Imports }
*
*
*
@@ -118,20 +117,4 @@ public interface PapyrusDiagram extends PapyrusView {
*/
EList getPaletteRules();
- /**
- * Returns the value of the 'Imports ' containment reference list.
- * The list contents are of type {@link org.eclipse.papyrus.infra.viewpoints.configuration.ElementImport}.
- *
- *
- * If the meaning of the 'Imports ' containment reference list isn't clear,
- * there really should be more of a description here...
- *
- *
- * @return the value of the 'Imports ' containment reference list.
- * @see org.eclipse.papyrus.infra.viewpoints.configuration.ConfigurationPackage#getPapyrusDiagram_Imports()
- * @model containment="true"
- * @generated
- */
- EList getImports();
-
} // PapyrusDiagram
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/ConfigurationFactoryImpl.java b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/ConfigurationFactoryImpl.java
index 7176aacd15f..eff070456ae 100755
--- a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/ConfigurationFactoryImpl.java
+++ b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/ConfigurationFactoryImpl.java
@@ -79,7 +79,7 @@ public class ConfigurationFactoryImpl extends EFactoryImpl implements Configurat
case ConfigurationPackage.PALETTE_RULE: return createPaletteRule();
case ConfigurationPackage.PATH_ELEMENT: return createPathElement();
case ConfigurationPackage.CATEGORY: return createCategory();
- case ConfigurationPackage.ELEMENT_IMPORT: return createElementImport();
+ case ConfigurationPackage.MODEL_AUTO_CREATE: return createModelAutoCreate();
default:
throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier");
}
@@ -210,9 +210,9 @@ public class ConfigurationFactoryImpl extends EFactoryImpl implements Configurat
*
* @generated
*/
- public ElementImport createElementImport() {
- ElementImportImpl elementImport = new ElementImportImpl();
- return elementImport;
+ public ModelAutoCreate createModelAutoCreate() {
+ ModelAutoCreateImpl modelAutoCreate = new ModelAutoCreateImpl();
+ return modelAutoCreate;
}
/**
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/ConfigurationPackageImpl.java b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/ConfigurationPackageImpl.java
index 74e443c3040..9eb2cf46154 100755
--- a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/ConfigurationPackageImpl.java
+++ b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/ConfigurationPackageImpl.java
@@ -23,7 +23,7 @@ import org.eclipse.papyrus.infra.viewpoints.configuration.Category;
import org.eclipse.papyrus.infra.viewpoints.configuration.ChildRule;
import org.eclipse.papyrus.infra.viewpoints.configuration.ConfigurationFactory;
import org.eclipse.papyrus.infra.viewpoints.configuration.ConfigurationPackage;
-import org.eclipse.papyrus.infra.viewpoints.configuration.ElementImport;
+import org.eclipse.papyrus.infra.viewpoints.configuration.ModelAutoCreate;
import org.eclipse.papyrus.infra.viewpoints.configuration.ModelRule;
import org.eclipse.papyrus.infra.viewpoints.configuration.OwningRule;
import org.eclipse.papyrus.infra.viewpoints.configuration.PaletteRule;
@@ -140,7 +140,7 @@ public class ConfigurationPackageImpl extends EPackageImpl implements Configurat
*
* @generated
*/
- private EClass elementImportEClass = null;
+ private EClass modelAutoCreateEClass = null;
/**
* Creates an instance of the model Package , registered with
@@ -378,15 +378,6 @@ public class ConfigurationPackageImpl extends EPackageImpl implements Configurat
return (EReference)papyrusDiagramEClass.getEStructuralFeatures().get(3);
}
- /**
- *
- *
- * @generated
- */
- public EReference getPapyrusDiagram_Imports() {
- return (EReference)papyrusDiagramEClass.getEStructuralFeatures().get(4);
- }
-
/**
*
*
@@ -450,15 +441,6 @@ public class ConfigurationPackageImpl extends EPackageImpl implements Configurat
return (EAttribute)modelRuleEClass.getEStructuralFeatures().get(2);
}
- /**
- *
- *
- * @generated
- */
- public EReference getModelRule_AutoSelectPath() {
- return (EReference)modelRuleEClass.getEStructuralFeatures().get(3);
- }
-
/**
*
*
@@ -495,6 +477,15 @@ public class ConfigurationPackageImpl extends EPackageImpl implements Configurat
return (EAttribute)owningRuleEClass.getEStructuralFeatures().get(2);
}
+ /**
+ *
+ *
+ * @generated
+ */
+ public EReference getOwningRule_NewModelPath() {
+ return (EReference)owningRuleEClass.getEStructuralFeatures().get(3);
+ }
+
/**
*
*
@@ -635,8 +626,17 @@ public class ConfigurationPackageImpl extends EPackageImpl implements Configurat
*
* @generated
*/
- public EClass getElementImport() {
- return elementImportEClass;
+ public EClass getModelAutoCreate() {
+ return modelAutoCreateEClass;
+ }
+
+ /**
+ *
+ *
+ * @generated
+ */
+ public EReference getModelAutoCreate_Feature() {
+ return (EReference)modelAutoCreateEClass.getEStructuralFeatures().get(0);
}
/**
@@ -644,8 +644,8 @@ public class ConfigurationPackageImpl extends EPackageImpl implements Configurat
*
* @generated
*/
- public EReference getElementImport_From() {
- return (EReference)elementImportEClass.getEStructuralFeatures().get(0);
+ public EReference getModelAutoCreate_Origin() {
+ return (EReference)modelAutoCreateEClass.getEStructuralFeatures().get(1);
}
/**
@@ -653,8 +653,8 @@ public class ConfigurationPackageImpl extends EPackageImpl implements Configurat
*
* @generated
*/
- public EReference getElementImport_Element() {
- return (EReference)elementImportEClass.getEStructuralFeatures().get(1);
+ public EReference getModelAutoCreate_CreationType() {
+ return (EReference)modelAutoCreateEClass.getEStructuralFeatures().get(2);
}
/**
@@ -707,7 +707,6 @@ public class ConfigurationPackageImpl extends EPackageImpl implements Configurat
createEAttribute(papyrusDiagramEClass, PAPYRUS_DIAGRAM__CUSTOM_STYLE);
createEReference(papyrusDiagramEClass, PAPYRUS_DIAGRAM__CHILD_RULES);
createEReference(papyrusDiagramEClass, PAPYRUS_DIAGRAM__PALETTE_RULES);
- createEReference(papyrusDiagramEClass, PAPYRUS_DIAGRAM__IMPORTS);
papyrusSyncTableEClass = createEClass(PAPYRUS_SYNC_TABLE);
@@ -721,12 +720,12 @@ public class ConfigurationPackageImpl extends EPackageImpl implements Configurat
createEReference(modelRuleEClass, MODEL_RULE__ELEMENT);
createEReference(modelRuleEClass, MODEL_RULE__STEREOTYPES);
createEAttribute(modelRuleEClass, MODEL_RULE__MULTIPLICITY);
- createEReference(modelRuleEClass, MODEL_RULE__AUTO_SELECT_PATH);
owningRuleEClass = createEClass(OWNING_RULE);
createEReference(owningRuleEClass, OWNING_RULE__ELEMENT);
createEReference(owningRuleEClass, OWNING_RULE__STEREOTYPES);
createEAttribute(owningRuleEClass, OWNING_RULE__MULTIPLICITY);
+ createEReference(owningRuleEClass, OWNING_RULE__NEW_MODEL_PATH);
childRuleEClass = createEClass(CHILD_RULE);
createEReference(childRuleEClass, CHILD_RULE__ELEMENT);
@@ -745,9 +744,10 @@ public class ConfigurationPackageImpl extends EPackageImpl implements Configurat
categoryEClass = createEClass(CATEGORY);
createEAttribute(categoryEClass, CATEGORY__NAME);
- elementImportEClass = createEClass(ELEMENT_IMPORT);
- createEReference(elementImportEClass, ELEMENT_IMPORT__FROM);
- createEReference(elementImportEClass, ELEMENT_IMPORT__ELEMENT);
+ modelAutoCreateEClass = createEClass(MODEL_AUTO_CREATE);
+ createEReference(modelAutoCreateEClass, MODEL_AUTO_CREATE__FEATURE);
+ createEReference(modelAutoCreateEClass, MODEL_AUTO_CREATE__ORIGIN);
+ createEReference(modelAutoCreateEClass, MODEL_AUTO_CREATE__CREATION_TYPE);
}
/**
@@ -815,7 +815,6 @@ public class ConfigurationPackageImpl extends EPackageImpl implements Configurat
initEAttribute(getPapyrusDiagram_CustomStyle(), ecorePackage.getEString(), "customStyle", null, 0, 1, PapyrusDiagram.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getPapyrusDiagram_ChildRules(), this.getChildRule(), null, "childRules", null, 0, -1, PapyrusDiagram.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getPapyrusDiagram_PaletteRules(), this.getPaletteRule(), null, "paletteRules", null, 0, -1, PapyrusDiagram.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEReference(getPapyrusDiagram_Imports(), this.getElementImport(), null, "imports", null, 0, -1, PapyrusDiagram.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(papyrusSyncTableEClass, PapyrusSyncTable.class, "PapyrusSyncTable", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
@@ -829,12 +828,12 @@ public class ConfigurationPackageImpl extends EPackageImpl implements Configurat
initEReference(getModelRule_Element(), ecorePackage.getEClass(), null, "element", null, 0, 1, ModelRule.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelRule_Stereotypes(), ecorePackage.getEClass(), null, "stereotypes", null, 0, -1, ModelRule.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getModelRule_Multiplicity(), ecorePackage.getEInt(), "multiplicity", "-1", 1, 1, ModelRule.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEReference(getModelRule_AutoSelectPath(), this.getPathElement(), null, "autoSelectPath", null, 0, -1, ModelRule.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(owningRuleEClass, OwningRule.class, "OwningRule", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEReference(getOwningRule_Element(), ecorePackage.getEClass(), null, "element", null, 0, 1, OwningRule.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getOwningRule_Stereotypes(), ecorePackage.getEClass(), null, "stereotypes", null, 0, -1, OwningRule.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getOwningRule_Multiplicity(), ecorePackage.getEInt(), "multiplicity", "-1", 1, 1, OwningRule.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getOwningRule_NewModelPath(), this.getModelAutoCreate(), null, "newModelPath", null, 0, -1, OwningRule.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(childRuleEClass, ChildRule.class, "ChildRule", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEReference(getChildRule_Element(), ecorePackage.getEClass(), null, "element", null, 0, 1, ChildRule.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
@@ -853,9 +852,10 @@ public class ConfigurationPackageImpl extends EPackageImpl implements Configurat
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);
- initEClass(elementImportEClass, ElementImport.class, "ElementImport", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
- initEReference(getElementImport_From(), this.getPapyrusDiagram(), null, "from", null, 1, 1, ElementImport.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEReference(getElementImport_Element(), ecorePackage.getEClass(), null, "element", null, 1, 1, ElementImport.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEClass(modelAutoCreateEClass, ModelAutoCreate.class, "ModelAutoCreate", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
+ initEReference(getModelAutoCreate_Feature(), ecorePackage.getEReference(), null, "feature", null, 1, 1, ModelAutoCreate.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getModelAutoCreate_Origin(), ecorePackage.getEClass(), null, "origin", null, 1, 1, ModelAutoCreate.class, IS_TRANSIENT, IS_VOLATILE, !IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, IS_DERIVED, IS_ORDERED);
+ initEReference(getModelAutoCreate_CreationType(), ecorePackage.getEClass(), null, "creationType", null, 1, 1, ModelAutoCreate.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);
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/ElementImportImpl.java b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/ElementImportImpl.java
deleted file mode 100755
index d1f39a65d94..00000000000
--- a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/ElementImportImpl.java
+++ /dev/null
@@ -1,228 +0,0 @@
-/**
- * Copyright (c) 2013 CEA LIST.
- *
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Laurent Wouters laurent.wouters@cea.fr - Initial API and implementation
- *
- *
- */
-package org.eclipse.papyrus.infra.viewpoints.configuration.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.MinimalEObjectImpl;
-
-import org.eclipse.papyrus.infra.viewpoints.configuration.ConfigurationPackage;
-import org.eclipse.papyrus.infra.viewpoints.configuration.ElementImport;
-import org.eclipse.papyrus.infra.viewpoints.configuration.PapyrusDiagram;
-
-/**
- *
- * An implementation of the model object 'Element Import '.
- *
- *
- * The following features are implemented:
- *
- * {@link org.eclipse.papyrus.infra.viewpoints.configuration.impl.ElementImportImpl#getFrom From }
- * {@link org.eclipse.papyrus.infra.viewpoints.configuration.impl.ElementImportImpl#getElement Element }
- *
- *
- *
- * @generated
- */
-public class ElementImportImpl extends MinimalEObjectImpl.Container implements ElementImport {
- /**
- * The cached value of the '{@link #getFrom() From }' reference.
- *
- *
- * @see #getFrom()
- * @generated
- * @ordered
- */
- protected PapyrusDiagram from;
-
- /**
- * The cached value of the '{@link #getElement() Element }' reference.
- *
- *
- * @see #getElement()
- * @generated
- * @ordered
- */
- protected EClass element;
-
- /**
- *
- *
- * @generated
- */
- protected ElementImportImpl() {
- super();
- }
-
- /**
- *
- *
- * @generated
- */
- @Override
- protected EClass eStaticClass() {
- return ConfigurationPackage.Literals.ELEMENT_IMPORT;
- }
-
- /**
- *
- *
- * @generated
- */
- public PapyrusDiagram getFrom() {
- if (from != null && from.eIsProxy()) {
- InternalEObject oldFrom = (InternalEObject)from;
- from = (PapyrusDiagram)eResolveProxy(oldFrom);
- if (from != oldFrom) {
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.RESOLVE, ConfigurationPackage.ELEMENT_IMPORT__FROM, oldFrom, from));
- }
- }
- return from;
- }
-
- /**
- *
- *
- * @generated
- */
- public PapyrusDiagram basicGetFrom() {
- return from;
- }
-
- /**
- *
- *
- * @generated
- */
- public void setFrom(PapyrusDiagram newFrom) {
- PapyrusDiagram oldFrom = from;
- from = newFrom;
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET, ConfigurationPackage.ELEMENT_IMPORT__FROM, oldFrom, from));
- }
-
- /**
- *
- *
- * @generated
- */
- public EClass getElement() {
- if (element != null && element.eIsProxy()) {
- InternalEObject oldElement = (InternalEObject)element;
- element = (EClass)eResolveProxy(oldElement);
- if (element != oldElement) {
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.RESOLVE, ConfigurationPackage.ELEMENT_IMPORT__ELEMENT, oldElement, element));
- }
- }
- return element;
- }
-
- /**
- *
- *
- * @generated
- */
- public EClass basicGetElement() {
- return element;
- }
-
- /**
- *
- *
- * @generated
- */
- public void setElement(EClass newElement) {
- EClass oldElement = element;
- element = newElement;
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET, ConfigurationPackage.ELEMENT_IMPORT__ELEMENT, oldElement, element));
- }
-
- /**
- *
- *
- * @generated
- */
- @Override
- public Object eGet(int featureID, boolean resolve, boolean coreType) {
- switch (featureID) {
- case ConfigurationPackage.ELEMENT_IMPORT__FROM:
- if (resolve) return getFrom();
- return basicGetFrom();
- case ConfigurationPackage.ELEMENT_IMPORT__ELEMENT:
- if (resolve) return getElement();
- return basicGetElement();
- }
- return super.eGet(featureID, resolve, coreType);
- }
-
- /**
- *
- *
- * @generated
- */
- @Override
- public void eSet(int featureID, Object newValue) {
- switch (featureID) {
- case ConfigurationPackage.ELEMENT_IMPORT__FROM:
- setFrom((PapyrusDiagram)newValue);
- return;
- case ConfigurationPackage.ELEMENT_IMPORT__ELEMENT:
- setElement((EClass)newValue);
- return;
- }
- super.eSet(featureID, newValue);
- }
-
- /**
- *
- *
- * @generated
- */
- @Override
- public void eUnset(int featureID) {
- switch (featureID) {
- case ConfigurationPackage.ELEMENT_IMPORT__FROM:
- setFrom((PapyrusDiagram)null);
- return;
- case ConfigurationPackage.ELEMENT_IMPORT__ELEMENT:
- setElement((EClass)null);
- return;
- }
- super.eUnset(featureID);
- }
-
- /**
- *
- *
- * @generated
- */
- @Override
- public boolean eIsSet(int featureID) {
- switch (featureID) {
- case ConfigurationPackage.ELEMENT_IMPORT__FROM:
- return from != null;
- case ConfigurationPackage.ELEMENT_IMPORT__ELEMENT:
- return element != null;
- }
- return super.eIsSet(featureID);
- }
-
-} //ElementImportImpl
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/ModelAutoCreateImpl.java b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/ModelAutoCreateImpl.java
new file mode 100755
index 00000000000..4f404b4ba70
--- /dev/null
+++ b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/ModelAutoCreateImpl.java
@@ -0,0 +1,256 @@
+/**
+ * Copyright (c) 2013 CEA LIST.
+ *
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Laurent Wouters laurent.wouters@cea.fr - Initial API and implementation
+ *
+ *
+ */
+package org.eclipse.papyrus.infra.viewpoints.configuration.impl;
+
+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.EReference;
+import org.eclipse.emf.ecore.InternalEObject;
+import org.eclipse.emf.ecore.impl.ENotificationImpl;
+import org.eclipse.emf.ecore.impl.MinimalEObjectImpl;
+import org.eclipse.papyrus.infra.viewpoints.configuration.ConfigurationPackage;
+import org.eclipse.papyrus.infra.viewpoints.configuration.ModelAutoCreate;
+import org.eclipse.papyrus.infra.viewpoints.configuration.OwningRule;
+
+/**
+ *
+ * An implementation of the model object 'Model Auto Create '.
+ *
+ *
+ * The following features are implemented:
+ *
+ * {@link org.eclipse.papyrus.infra.viewpoints.configuration.impl.ModelAutoCreateImpl#getFeature Feature }
+ * {@link org.eclipse.papyrus.infra.viewpoints.configuration.impl.ModelAutoCreateImpl#getOrigin Origin }
+ * {@link org.eclipse.papyrus.infra.viewpoints.configuration.impl.ModelAutoCreateImpl#getCreationType Creation Type }
+ *
+ *
+ *
+ * @generated
+ */
+public class ModelAutoCreateImpl extends MinimalEObjectImpl.Container implements ModelAutoCreate {
+ /**
+ * The cached value of the '{@link #getFeature() Feature }' reference.
+ *
+ *
+ * @see #getFeature()
+ * @generated
+ * @ordered
+ */
+ protected EReference feature;
+
+ /**
+ * The cached value of the '{@link #getCreationType() Creation Type }' reference.
+ *
+ *
+ * @see #getCreationType()
+ * @generated
+ * @ordered
+ */
+ protected EClass creationType;
+
+ /**
+ *
+ *
+ * @generated
+ */
+ protected ModelAutoCreateImpl() {
+ super();
+ }
+
+ /**
+ *
+ *
+ * @generated
+ */
+ @Override
+ protected EClass eStaticClass() {
+ return ConfigurationPackage.Literals.MODEL_AUTO_CREATE;
+ }
+
+ /**
+ *
+ *
+ * @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, ConfigurationPackage.MODEL_AUTO_CREATE__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, ConfigurationPackage.MODEL_AUTO_CREATE__FEATURE, oldFeature, feature));
+ }
+
+ /**
+ *
+ *
+ * @generated
+ */
+ public EClass getOrigin() {
+ EClass origin = basicGetOrigin();
+ return origin != null && origin.eIsProxy() ? (EClass)eResolveProxy((InternalEObject)origin) : origin;
+ }
+
+ /**
+ *
+ *
+ */
+ public EClass basicGetOrigin() {
+ OwningRule rule = (OwningRule) this.eContainer();
+ EList list = rule.getNewModelPath();
+ int index = list.indexOf(this);
+ if (index == 0)
+ return rule.getElement();
+ return list.get(index - 1).getCreationType();
+ }
+
+ /**
+ *
+ *
+ * @generated
+ */
+ public EClass getCreationType() {
+ if (creationType != null && creationType.eIsProxy()) {
+ InternalEObject oldCreationType = (InternalEObject)creationType;
+ creationType = (EClass)eResolveProxy(oldCreationType);
+ if (creationType != oldCreationType) {
+ if (eNotificationRequired())
+ eNotify(new ENotificationImpl(this, Notification.RESOLVE, ConfigurationPackage.MODEL_AUTO_CREATE__CREATION_TYPE, oldCreationType, creationType));
+ }
+ }
+ return creationType;
+ }
+
+ /**
+ *
+ *
+ * @generated
+ */
+ public EClass basicGetCreationType() {
+ return creationType;
+ }
+
+ /**
+ *
+ *
+ * @generated
+ */
+ public void setCreationType(EClass newCreationType) {
+ EClass oldCreationType = creationType;
+ creationType = newCreationType;
+ if (eNotificationRequired())
+ eNotify(new ENotificationImpl(this, Notification.SET, ConfigurationPackage.MODEL_AUTO_CREATE__CREATION_TYPE, oldCreationType, creationType));
+ }
+
+ /**
+ *
+ *
+ * @generated
+ */
+ @Override
+ public Object eGet(int featureID, boolean resolve, boolean coreType) {
+ switch (featureID) {
+ case ConfigurationPackage.MODEL_AUTO_CREATE__FEATURE:
+ if (resolve) return getFeature();
+ return basicGetFeature();
+ case ConfigurationPackage.MODEL_AUTO_CREATE__ORIGIN:
+ if (resolve) return getOrigin();
+ return basicGetOrigin();
+ case ConfigurationPackage.MODEL_AUTO_CREATE__CREATION_TYPE:
+ if (resolve) return getCreationType();
+ return basicGetCreationType();
+ }
+ return super.eGet(featureID, resolve, coreType);
+ }
+
+ /**
+ *
+ *
+ * @generated
+ */
+ @Override
+ public void eSet(int featureID, Object newValue) {
+ switch (featureID) {
+ case ConfigurationPackage.MODEL_AUTO_CREATE__FEATURE:
+ setFeature((EReference)newValue);
+ return;
+ case ConfigurationPackage.MODEL_AUTO_CREATE__CREATION_TYPE:
+ setCreationType((EClass)newValue);
+ return;
+ }
+ super.eSet(featureID, newValue);
+ }
+
+ /**
+ *
+ *
+ * @generated
+ */
+ @Override
+ public void eUnset(int featureID) {
+ switch (featureID) {
+ case ConfigurationPackage.MODEL_AUTO_CREATE__FEATURE:
+ setFeature((EReference)null);
+ return;
+ case ConfigurationPackage.MODEL_AUTO_CREATE__CREATION_TYPE:
+ setCreationType((EClass)null);
+ return;
+ }
+ super.eUnset(featureID);
+ }
+
+ /**
+ *
+ *
+ * @generated
+ */
+ @Override
+ public boolean eIsSet(int featureID) {
+ switch (featureID) {
+ case ConfigurationPackage.MODEL_AUTO_CREATE__FEATURE:
+ return feature != null;
+ case ConfigurationPackage.MODEL_AUTO_CREATE__ORIGIN:
+ return basicGetOrigin() != null;
+ case ConfigurationPackage.MODEL_AUTO_CREATE__CREATION_TYPE:
+ return creationType != null;
+ }
+ return super.eIsSet(featureID);
+ }
+
+} //ModelAutoCreateImpl
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/ModelRuleImpl.java b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/ModelRuleImpl.java
index 75149e650b0..73683edb0db 100755
--- a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/ModelRuleImpl.java
+++ b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/ModelRuleImpl.java
@@ -15,17 +15,13 @@ package org.eclipse.papyrus.infra.viewpoints.configuration.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.InternalEList;
import org.eclipse.papyrus.infra.viewpoints.configuration.ConfigurationPackage;
import org.eclipse.papyrus.infra.viewpoints.configuration.ModelRule;
-import org.eclipse.papyrus.infra.viewpoints.configuration.PathElement;
/**
*
@@ -37,7 +33,6 @@ import org.eclipse.papyrus.infra.viewpoints.configuration.PathElement;
* {@link org.eclipse.papyrus.infra.viewpoints.configuration.impl.ModelRuleImpl#getElement Element }
* {@link org.eclipse.papyrus.infra.viewpoints.configuration.impl.ModelRuleImpl#getStereotypes Stereotypes }
* {@link org.eclipse.papyrus.infra.viewpoints.configuration.impl.ModelRuleImpl#getMultiplicity Multiplicity }
- * {@link org.eclipse.papyrus.infra.viewpoints.configuration.impl.ModelRuleImpl#getAutoSelectPath Auto Select Path }
*
*
*
@@ -84,16 +79,6 @@ public class ModelRuleImpl extends RuleImpl implements ModelRule {
*/
protected int multiplicity = MULTIPLICITY_EDEFAULT;
- /**
- * The cached value of the '{@link #getAutoSelectPath() Auto Select Path }' containment reference list.
- *
- *
- * @see #getAutoSelectPath()
- * @generated
- * @ordered
- */
- protected EList autoSelectPath;
-
/**
*
*
@@ -184,32 +169,6 @@ public class ModelRuleImpl extends RuleImpl implements ModelRule {
eNotify(new ENotificationImpl(this, Notification.SET, ConfigurationPackage.MODEL_RULE__MULTIPLICITY, oldMultiplicity, multiplicity));
}
- /**
- *
- *
- * @generated
- */
- public EList getAutoSelectPath() {
- if (autoSelectPath == null) {
- autoSelectPath = new EObjectContainmentEList(PathElement.class, this, ConfigurationPackage.MODEL_RULE__AUTO_SELECT_PATH);
- }
- return autoSelectPath;
- }
-
- /**
- *
- *
- * @generated
- */
- @Override
- public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
- switch (featureID) {
- case ConfigurationPackage.MODEL_RULE__AUTO_SELECT_PATH:
- return ((InternalEList>)getAutoSelectPath()).basicRemove(otherEnd, msgs);
- }
- return super.eInverseRemove(otherEnd, featureID, msgs);
- }
-
/**
*
*
@@ -225,8 +184,6 @@ public class ModelRuleImpl extends RuleImpl implements ModelRule {
return getStereotypes();
case ConfigurationPackage.MODEL_RULE__MULTIPLICITY:
return getMultiplicity();
- case ConfigurationPackage.MODEL_RULE__AUTO_SELECT_PATH:
- return getAutoSelectPath();
}
return super.eGet(featureID, resolve, coreType);
}
@@ -250,10 +207,6 @@ public class ModelRuleImpl extends RuleImpl implements ModelRule {
case ConfigurationPackage.MODEL_RULE__MULTIPLICITY:
setMultiplicity((Integer)newValue);
return;
- case ConfigurationPackage.MODEL_RULE__AUTO_SELECT_PATH:
- getAutoSelectPath().clear();
- getAutoSelectPath().addAll((Collection extends PathElement>)newValue);
- return;
}
super.eSet(featureID, newValue);
}
@@ -275,9 +228,6 @@ public class ModelRuleImpl extends RuleImpl implements ModelRule {
case ConfigurationPackage.MODEL_RULE__MULTIPLICITY:
setMultiplicity(MULTIPLICITY_EDEFAULT);
return;
- case ConfigurationPackage.MODEL_RULE__AUTO_SELECT_PATH:
- getAutoSelectPath().clear();
- return;
}
super.eUnset(featureID);
}
@@ -296,8 +246,6 @@ public class ModelRuleImpl extends RuleImpl implements ModelRule {
return stereotypes != null && !stereotypes.isEmpty();
case ConfigurationPackage.MODEL_RULE__MULTIPLICITY:
return multiplicity != MULTIPLICITY_EDEFAULT;
- case ConfigurationPackage.MODEL_RULE__AUTO_SELECT_PATH:
- return autoSelectPath != null && !autoSelectPath.isEmpty();
}
return super.eIsSet(featureID);
}
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/OwningRuleImpl.java b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/OwningRuleImpl.java
index 4b75d1292e8..4cb3c9bff4f 100755
--- a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/OwningRuleImpl.java
+++ b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/OwningRuleImpl.java
@@ -16,14 +16,18 @@ package org.eclipse.papyrus.infra.viewpoints.configuration.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.InternalEList;
import org.eclipse.papyrus.infra.viewpoints.configuration.ConfigurationPackage;
+import org.eclipse.papyrus.infra.viewpoints.configuration.ModelAutoCreate;
import org.eclipse.papyrus.infra.viewpoints.configuration.OwningRule;
/**
@@ -36,6 +40,7 @@ import org.eclipse.papyrus.infra.viewpoints.configuration.OwningRule;
* {@link org.eclipse.papyrus.infra.viewpoints.configuration.impl.OwningRuleImpl#getElement Element }
* {@link org.eclipse.papyrus.infra.viewpoints.configuration.impl.OwningRuleImpl#getStereotypes Stereotypes }
* {@link org.eclipse.papyrus.infra.viewpoints.configuration.impl.OwningRuleImpl#getMultiplicity Multiplicity }
+ * {@link org.eclipse.papyrus.infra.viewpoints.configuration.impl.OwningRuleImpl#getNewModelPath New Model Path }
*
*
*
@@ -82,6 +87,16 @@ public class OwningRuleImpl extends RuleImpl implements OwningRule {
*/
protected int multiplicity = MULTIPLICITY_EDEFAULT;
+ /**
+ * The cached value of the '{@link #getNewModelPath() New Model Path }' containment reference list.
+ *
+ *
+ * @see #getNewModelPath()
+ * @generated
+ * @ordered
+ */
+ protected EList newModelPath;
+
/**
*
*
@@ -172,6 +187,32 @@ public class OwningRuleImpl extends RuleImpl implements OwningRule {
eNotify(new ENotificationImpl(this, Notification.SET, ConfigurationPackage.OWNING_RULE__MULTIPLICITY, oldMultiplicity, multiplicity));
}
+ /**
+ *
+ *
+ * @generated
+ */
+ public EList getNewModelPath() {
+ if (newModelPath == null) {
+ newModelPath = new EObjectContainmentEList(ModelAutoCreate.class, this, ConfigurationPackage.OWNING_RULE__NEW_MODEL_PATH);
+ }
+ return newModelPath;
+ }
+
+ /**
+ *
+ *
+ * @generated
+ */
+ @Override
+ public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
+ switch (featureID) {
+ case ConfigurationPackage.OWNING_RULE__NEW_MODEL_PATH:
+ return ((InternalEList>)getNewModelPath()).basicRemove(otherEnd, msgs);
+ }
+ return super.eInverseRemove(otherEnd, featureID, msgs);
+ }
+
/**
*
*
@@ -187,6 +228,8 @@ public class OwningRuleImpl extends RuleImpl implements OwningRule {
return getStereotypes();
case ConfigurationPackage.OWNING_RULE__MULTIPLICITY:
return getMultiplicity();
+ case ConfigurationPackage.OWNING_RULE__NEW_MODEL_PATH:
+ return getNewModelPath();
}
return super.eGet(featureID, resolve, coreType);
}
@@ -210,6 +253,10 @@ public class OwningRuleImpl extends RuleImpl implements OwningRule {
case ConfigurationPackage.OWNING_RULE__MULTIPLICITY:
setMultiplicity((Integer)newValue);
return;
+ case ConfigurationPackage.OWNING_RULE__NEW_MODEL_PATH:
+ getNewModelPath().clear();
+ getNewModelPath().addAll((Collection extends ModelAutoCreate>)newValue);
+ return;
}
super.eSet(featureID, newValue);
}
@@ -231,6 +278,9 @@ public class OwningRuleImpl extends RuleImpl implements OwningRule {
case ConfigurationPackage.OWNING_RULE__MULTIPLICITY:
setMultiplicity(MULTIPLICITY_EDEFAULT);
return;
+ case ConfigurationPackage.OWNING_RULE__NEW_MODEL_PATH:
+ getNewModelPath().clear();
+ return;
}
super.eUnset(featureID);
}
@@ -249,6 +299,8 @@ public class OwningRuleImpl extends RuleImpl implements OwningRule {
return stereotypes != null && !stereotypes.isEmpty();
case ConfigurationPackage.OWNING_RULE__MULTIPLICITY:
return multiplicity != MULTIPLICITY_EDEFAULT;
+ case ConfigurationPackage.OWNING_RULE__NEW_MODEL_PATH:
+ return newModelPath != null && !newModelPath.isEmpty();
}
return super.eIsSet(featureID);
}
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/PapyrusDiagramImpl.java b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/PapyrusDiagramImpl.java
index 7aa81c0eb8f..e2dac6f2c9a 100755
--- a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/PapyrusDiagramImpl.java
+++ b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/PapyrusDiagramImpl.java
@@ -24,7 +24,6 @@ import org.eclipse.emf.ecore.util.EObjectContainmentEList;
import org.eclipse.emf.ecore.util.InternalEList;
import org.eclipse.papyrus.infra.viewpoints.configuration.ChildRule;
import org.eclipse.papyrus.infra.viewpoints.configuration.ConfigurationPackage;
-import org.eclipse.papyrus.infra.viewpoints.configuration.ElementImport;
import org.eclipse.papyrus.infra.viewpoints.configuration.PaletteRule;
import org.eclipse.papyrus.infra.viewpoints.configuration.PapyrusDiagram;
@@ -39,7 +38,6 @@ import org.eclipse.papyrus.infra.viewpoints.configuration.PapyrusDiagram;
* {@link org.eclipse.papyrus.infra.viewpoints.configuration.impl.PapyrusDiagramImpl#getCustomStyle Custom Style }
* {@link org.eclipse.papyrus.infra.viewpoints.configuration.impl.PapyrusDiagramImpl#getChildRules Child Rules }
* {@link org.eclipse.papyrus.infra.viewpoints.configuration.impl.PapyrusDiagramImpl#getPaletteRules Palette Rules }
- * {@link org.eclipse.papyrus.infra.viewpoints.configuration.impl.PapyrusDiagramImpl#getImports Imports }
*
*
*
@@ -106,16 +104,6 @@ public class PapyrusDiagramImpl extends PapyrusViewImpl implements PapyrusDiagra
*/
protected EList paletteRules;
- /**
- * The cached value of the '{@link #getImports() Imports }' containment reference list.
- *
- *
- * @see #getImports()
- * @generated
- * @ordered
- */
- protected EList imports;
-
/**
*
*
@@ -201,18 +189,6 @@ public class PapyrusDiagramImpl extends PapyrusViewImpl implements PapyrusDiagra
return paletteRules;
}
- /**
- *
- *
- * @generated
- */
- public EList getImports() {
- if (imports == null) {
- imports = new EObjectContainmentEList(ElementImport.class, this, ConfigurationPackage.PAPYRUS_DIAGRAM__IMPORTS);
- }
- return imports;
- }
-
/**
*
*
@@ -225,8 +201,6 @@ public class PapyrusDiagramImpl extends PapyrusViewImpl implements PapyrusDiagra
return ((InternalEList>)getChildRules()).basicRemove(otherEnd, msgs);
case ConfigurationPackage.PAPYRUS_DIAGRAM__PALETTE_RULES:
return ((InternalEList>)getPaletteRules()).basicRemove(otherEnd, msgs);
- case ConfigurationPackage.PAPYRUS_DIAGRAM__IMPORTS:
- return ((InternalEList>)getImports()).basicRemove(otherEnd, msgs);
}
return super.eInverseRemove(otherEnd, featureID, msgs);
}
@@ -247,8 +221,6 @@ public class PapyrusDiagramImpl extends PapyrusViewImpl implements PapyrusDiagra
return getChildRules();
case ConfigurationPackage.PAPYRUS_DIAGRAM__PALETTE_RULES:
return getPaletteRules();
- case ConfigurationPackage.PAPYRUS_DIAGRAM__IMPORTS:
- return getImports();
}
return super.eGet(featureID, resolve, coreType);
}
@@ -276,10 +248,6 @@ public class PapyrusDiagramImpl extends PapyrusViewImpl implements PapyrusDiagra
getPaletteRules().clear();
getPaletteRules().addAll((Collection extends PaletteRule>)newValue);
return;
- case ConfigurationPackage.PAPYRUS_DIAGRAM__IMPORTS:
- getImports().clear();
- getImports().addAll((Collection extends ElementImport>)newValue);
- return;
}
super.eSet(featureID, newValue);
}
@@ -304,9 +272,6 @@ public class PapyrusDiagramImpl extends PapyrusViewImpl implements PapyrusDiagra
case ConfigurationPackage.PAPYRUS_DIAGRAM__PALETTE_RULES:
getPaletteRules().clear();
return;
- case ConfigurationPackage.PAPYRUS_DIAGRAM__IMPORTS:
- getImports().clear();
- return;
}
super.eUnset(featureID);
}
@@ -327,8 +292,6 @@ public class PapyrusDiagramImpl extends PapyrusViewImpl implements PapyrusDiagra
return childRules != null && !childRules.isEmpty();
case ConfigurationPackage.PAPYRUS_DIAGRAM__PALETTE_RULES:
return paletteRules != null && !paletteRules.isEmpty();
- case ConfigurationPackage.PAPYRUS_DIAGRAM__IMPORTS:
- return imports != null && !imports.isEmpty();
}
return super.eIsSet(featureID);
}
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/PathElementImpl.java b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/PathElementImpl.java
index 20cf5683b4d..aef427bf7d6 100755
--- a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/PathElementImpl.java
+++ b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/impl/PathElementImpl.java
@@ -22,9 +22,6 @@ import org.eclipse.emf.ecore.impl.ENotificationImpl;
import org.eclipse.emf.ecore.impl.MinimalEObjectImpl;
import org.eclipse.papyrus.infra.viewpoints.configuration.ChildRule;
import org.eclipse.papyrus.infra.viewpoints.configuration.ConfigurationPackage;
-import org.eclipse.papyrus.infra.viewpoints.configuration.ModelRule;
-import org.eclipse.papyrus.infra.viewpoints.configuration.OwningRule;
-import org.eclipse.papyrus.infra.viewpoints.configuration.PapyrusView;
import org.eclipse.papyrus.infra.viewpoints.configuration.PathElement;
/**
@@ -125,25 +122,10 @@ public class PathElementImpl extends MinimalEObjectImpl.Container implements Pat
*
*/
public EClass basicGetOrigin() {
- if (this.eContainer() instanceof ChildRule)
- return basicGetOriginChildRule();
- return basicGetOriginModelRule();
- }
-
- private EClass basicGetOriginChildRule() {
ChildRule rule = (ChildRule) this.eContainer();
return basicGetOriginFrom(rule.getInsertionPath(), rule.getOrigin());
}
- private EClass basicGetOriginModelRule() {
- ModelRule rule = (ModelRule)this.eContainer();
- PapyrusView view = (PapyrusView) rule.eContainer();
- OwningRule or = (view.getOwningRules().size() >= 1) ? view.getOwningRules().get(0) : null;
- if (or != null)
- return basicGetOriginFrom(rule.getAutoSelectPath(), or.getElement());
- return null;
- }
-
private EClass basicGetOriginFrom(EList list, EClass from) {
EClass current = from;
int index = 0;
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/util/ConfigurationAdapterFactory.java b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/util/ConfigurationAdapterFactory.java
index b4a8bfdad47..1b8eb67a6a3 100755
--- a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/util/ConfigurationAdapterFactory.java
+++ b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/util/ConfigurationAdapterFactory.java
@@ -132,8 +132,8 @@ public class ConfigurationAdapterFactory extends AdapterFactoryImpl {
return createCategoryAdapter();
}
@Override
- public Adapter caseElementImport(ElementImport object) {
- return createElementImportAdapter();
+ public Adapter caseModelAutoCreate(ModelAutoCreate object) {
+ return createModelAutoCreateAdapter();
}
@Override
public Adapter caseArchitectureFramework(ArchitectureFramework object) {
@@ -354,16 +354,16 @@ public class ConfigurationAdapterFactory extends AdapterFactoryImpl {
}
/**
- * Creates a new adapter for an object of class '{@link org.eclipse.papyrus.infra.viewpoints.configuration.ElementImport Element Import }'.
+ * Creates a new adapter for an object of class '{@link org.eclipse.papyrus.infra.viewpoints.configuration.ModelAutoCreate Model Auto Create }'.
*
* 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.papyrus.infra.viewpoints.configuration.ElementImport
+ * @see org.eclipse.papyrus.infra.viewpoints.configuration.ModelAutoCreate
* @generated
*/
- public Adapter createElementImportAdapter() {
+ public Adapter createModelAutoCreateAdapter() {
return null;
}
diff --git a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/util/ConfigurationSwitch.java b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/util/ConfigurationSwitch.java
index 4b8fceb879a..7d3018c6d6b 100755
--- a/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/util/ConfigurationSwitch.java
+++ b/plugins/infra/viewpoints/org.eclipse.papyrus.infra.viewpoints.configuration/src/org/eclipse/papyrus/infra/viewpoints/configuration/util/ConfigurationSwitch.java
@@ -175,9 +175,9 @@ public class ConfigurationSwitch extends Switch {
if (result == null) result = defaultCase(theEObject);
return result;
}
- case ConfigurationPackage.ELEMENT_IMPORT: {
- ElementImport elementImport = (ElementImport)theEObject;
- T result = caseElementImport(elementImport);
+ case ConfigurationPackage.MODEL_AUTO_CREATE: {
+ ModelAutoCreate modelAutoCreate = (ModelAutoCreate)theEObject;
+ T result = caseModelAutoCreate(modelAutoCreate);
if (result == null) result = defaultCase(theEObject);
return result;
}
@@ -381,17 +381,17 @@ public class ConfigurationSwitch extends Switch {
}
/**
- * Returns the result of interpreting the object as an instance of 'Element Import '.
+ * Returns the result of interpreting the object as an instance of 'Model Auto Create '.
*
* 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 Import '.
+ * @return the result of interpreting the object as an instance of 'Model Auto Create '.
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
* @generated
*/
- public T caseElementImport(ElementImport object) {
+ public T caseModelAutoCreate(ModelAutoCreate object) {
return null;
}
--
cgit v1.2.3