Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVincent Lorenzo2018-04-10 14:40:41 +0000
committervincent lorenzo2018-04-12 15:52:40 +0000
commitfcad4d4c79d81f7a3c9ba7fcb4e7138687bde6d5 (patch)
tree2da9ee46d1abc6373be7221a30980ae119c627a0 /plugins/infra
parent8733a658a78d04d8faf97264d1d75ad280208111 (diff)
downloadorg.eclipse.papyrus-fcad4d4c79d81f7a3c9ba7fcb4e7138687bde6d5.tar.gz
org.eclipse.papyrus-fcad4d4c79d81f7a3c9ba7fcb4e7138687bde6d5.tar.xz
org.eclipse.papyrus-fcad4d4c79d81f7a3c9ba7fcb4e7138687bde6d5.zip
Bug 531645: [Table] The new child of the TableConfiguration editors doesn't provides all the existing expressions
- previous commit on this subject doesn't fix the bug for GenericRelationshipMatrixCellEditorConfiguration#cellContentsFilter - regenerate all and change some generation option in the genmodel Change-Id: I74449d78fd443b53201c8f3377820bd835d095b0 Signed-off-by: Vincent Lorenzo <vincent.lorenzo@cea.fr>
Diffstat (limited to 'plugins/infra')
-rw-r--r--plugins/infra/nattable/org.eclipse.papyrus.infra.nattable.model.edit/plugin.xml2
-rwxr-xr-xplugins/infra/nattable/org.eclipse.papyrus.infra.nattable.model.edit/src-gen/org/eclipse/papyrus/infra/nattable/model/nattable/nattablecelleditor/provider/GenericRelationshipMatrixCellEditorConfigurationItemProvider.java307
-rwxr-xr-xplugins/infra/nattable/org.eclipse.papyrus.infra.nattable.model.edit/src/org/eclipse/papyrus/internal/infra/nattable/model/nattable/nattableaxisconfiguration/provider/ExtendedBooleanEObjectExpressionChildCreationExtender.java9
-rw-r--r--plugins/infra/nattable/org.eclipse.papyrus.infra.nattable.model/model/nattable.genmodel14
4 files changed, 201 insertions, 131 deletions
diff --git a/plugins/infra/nattable/org.eclipse.papyrus.infra.nattable.model.edit/plugin.xml b/plugins/infra/nattable/org.eclipse.papyrus.infra.nattable.model.edit/plugin.xml
index c1089d4d591..0546f11a099 100644
--- a/plugins/infra/nattable/org.eclipse.papyrus.infra.nattable.model.edit/plugin.xml
+++ b/plugins/infra/nattable/org.eclipse.papyrus.infra.nattable.model.edit/plugin.xml
@@ -72,7 +72,7 @@
<!-- @generated nattable -->
<factory
uri="http://www.eclipse.org/papyrus/nattable/model/table/nattableaxisconfiguration"
- class="org.eclipse.papyrus.internal.infra.nattable.model.nattable.nattableaxisconfiguration.provider.NattableaxisconfigurationItemProviderAdapterFactory"
+ class="org.eclipse.papyrus.infra.nattable.model.nattable.nattableaxisconfiguration.provider.NattableaxisconfigurationItemProviderAdapterFactory"
supportedTypes=
"org.eclipse.emf.edit.provider.IEditingDomainItemProvider
org.eclipse.emf.edit.provider.IStructuredItemContentProvider
diff --git a/plugins/infra/nattable/org.eclipse.papyrus.infra.nattable.model.edit/src-gen/org/eclipse/papyrus/infra/nattable/model/nattable/nattablecelleditor/provider/GenericRelationshipMatrixCellEditorConfigurationItemProvider.java b/plugins/infra/nattable/org.eclipse.papyrus.infra.nattable.model.edit/src-gen/org/eclipse/papyrus/infra/nattable/model/nattable/nattablecelleditor/provider/GenericRelationshipMatrixCellEditorConfigurationItemProvider.java
index 3dddf0360fd..6b7b0b4d71e 100755
--- a/plugins/infra/nattable/org.eclipse.papyrus.infra.nattable.model.edit/src-gen/org/eclipse/papyrus/infra/nattable/model/nattable/nattablecelleditor/provider/GenericRelationshipMatrixCellEditorConfigurationItemProvider.java
+++ b/plugins/infra/nattable/org.eclipse.papyrus.infra.nattable.model.edit/src-gen/org/eclipse/papyrus/infra/nattable/model/nattable/nattablecelleditor/provider/GenericRelationshipMatrixCellEditorConfigurationItemProvider.java
@@ -28,6 +28,7 @@ import org.eclipse.emf.edit.provider.IItemPropertyDescriptor;
import org.eclipse.emf.edit.provider.ItemPropertyDescriptor;
import org.eclipse.emf.edit.provider.ViewerNotification;
+import org.eclipse.papyrus.infra.emf.expressions.booleanexpressions.BooleanExpressionsFactory;
import org.eclipse.papyrus.infra.nattable.model.nattable.nattableaxis.NattableaxisFactory;
import org.eclipse.papyrus.infra.nattable.model.nattable.nattablecelleditor.GenericRelationshipMatrixCellEditorConfiguration;
import org.eclipse.papyrus.infra.nattable.model.nattable.nattablecelleditor.NattablecelleditorPackage;
@@ -35,13 +36,11 @@ import org.eclipse.papyrus.infra.nattable.model.nattable.nattablecelleditor.Natt
import org.eclipse.papyrus.infra.nattable.model.nattable.nattablestyle.provider.StyledElementItemProvider;
import org.eclipse.papyrus.infra.nattable.model.nattable.nattablewrapper.NattablewrapperFactory;
-import org.eclipse.papyrus.infra.nattable.model.nattable.provider.NattableEditPlugin;
/**
* This is the item provider adapter for a {@link org.eclipse.papyrus.infra.nattable.model.nattable.nattablecelleditor.GenericRelationshipMatrixCellEditorConfiguration} object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- *
* @generated
*/
public class GenericRelationshipMatrixCellEditorConfigurationItemProvider extends StyledElementItemProvider {
@@ -49,7 +48,6 @@ public class GenericRelationshipMatrixCellEditorConfigurationItemProvider extend
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- *
* @generated
*/
public GenericRelationshipMatrixCellEditorConfigurationItemProvider(AdapterFactory adapterFactory) {
@@ -60,7 +58,6 @@ public class GenericRelationshipMatrixCellEditorConfigurationItemProvider extend
* This returns the property descriptors for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- *
* @generated
*/
@Override
@@ -81,105 +78,110 @@ public class GenericRelationshipMatrixCellEditorConfigurationItemProvider extend
* This adds a property descriptor for the Cell Editor Id feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- *
* @generated
*/
protected void addCellEditorIdPropertyDescriptor(Object object) {
- itemPropertyDescriptors.add(createItemPropertyDescriptor(((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_ICellEditorConfiguration_cellEditorId_feature"), //$NON-NLS-1$
- getString("_UI_PropertyDescriptor_description", "_UI_ICellEditorConfiguration_cellEditorId_feature", "_UI_ICellEditorConfiguration_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
- NattablecelleditorPackage.Literals.ICELL_EDITOR_CONFIGURATION__CELL_EDITOR_ID,
- true,
- false,
- false,
- ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
- null,
- null));
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_ICellEditorConfiguration_cellEditorId_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_ICellEditorConfiguration_cellEditorId_feature", "_UI_ICellEditorConfiguration_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ NattablecelleditorPackage.Literals.ICELL_EDITOR_CONFIGURATION__CELL_EDITOR_ID,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
+ null,
+ null));
}
/**
* This adds a property descriptor for the Direction feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- *
* @generated
*/
protected void addDirectionPropertyDescriptor(Object object) {
- itemPropertyDescriptors.add(createItemPropertyDescriptor(((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_GenericRelationshipMatrixCellEditorConfiguration_direction_feature"), //$NON-NLS-1$
- getString("_UI_PropertyDescriptor_description", "_UI_GenericRelationshipMatrixCellEditorConfiguration_direction_feature", "_UI_GenericRelationshipMatrixCellEditorConfiguration_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
- NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__DIRECTION,
- true,
- false,
- false,
- ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
- null,
- null));
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_GenericRelationshipMatrixCellEditorConfiguration_direction_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_GenericRelationshipMatrixCellEditorConfiguration_direction_feature", "_UI_GenericRelationshipMatrixCellEditorConfiguration_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__DIRECTION,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
+ null,
+ null));
}
/**
* This adds a property descriptor for the Cell Contents Filter feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- *
* @generated
*/
protected void addCellContentsFilterPropertyDescriptor(Object object) {
- itemPropertyDescriptors.add(createItemPropertyDescriptor(((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_GenericRelationshipMatrixCellEditorConfiguration_cellContentsFilter_feature"), //$NON-NLS-1$
- getString("_UI_PropertyDescriptor_description", "_UI_GenericRelationshipMatrixCellEditorConfiguration_cellContentsFilter_feature", "_UI_GenericRelationshipMatrixCellEditorConfiguration_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
- NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__CELL_CONTENTS_FILTER,
- true,
- false,
- true,
- null,
- null,
- null));
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_GenericRelationshipMatrixCellEditorConfiguration_cellContentsFilter_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_GenericRelationshipMatrixCellEditorConfiguration_cellContentsFilter_feature", "_UI_GenericRelationshipMatrixCellEditorConfiguration_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__CELL_CONTENTS_FILTER,
+ true,
+ false,
+ true,
+ null,
+ null,
+ null));
}
/**
* This adds a property descriptor for the Edited Element feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- *
* @generated
*/
protected void addEditedElementPropertyDescriptor(Object object) {
- itemPropertyDescriptors.add(createItemPropertyDescriptor(((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_GenericRelationshipMatrixCellEditorConfiguration_editedElement_feature"), //$NON-NLS-1$
- getString("_UI_PropertyDescriptor_description", "_UI_GenericRelationshipMatrixCellEditorConfiguration_editedElement_feature", "_UI_GenericRelationshipMatrixCellEditorConfiguration_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
- NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__EDITED_ELEMENT,
- true,
- false,
- true,
- null,
- null,
- null));
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_GenericRelationshipMatrixCellEditorConfiguration_editedElement_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_GenericRelationshipMatrixCellEditorConfiguration_editedElement_feature", "_UI_GenericRelationshipMatrixCellEditorConfiguration_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__EDITED_ELEMENT,
+ true,
+ false,
+ true,
+ null,
+ null,
+ null));
}
/**
* This adds a property descriptor for the Relationship Owner Strategy feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- *
* @generated
*/
protected void addRelationshipOwnerStrategyPropertyDescriptor(Object object) {
- itemPropertyDescriptors.add(createItemPropertyDescriptor(((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_GenericRelationshipMatrixCellEditorConfiguration_relationshipOwnerStrategy_feature"), //$NON-NLS-1$
- getString("_UI_PropertyDescriptor_description", "_UI_GenericRelationshipMatrixCellEditorConfiguration_relationshipOwnerStrategy_feature", "_UI_GenericRelationshipMatrixCellEditorConfiguration_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
- NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_STRATEGY,
- true,
- false,
- false,
- ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
- null,
- null));
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_GenericRelationshipMatrixCellEditorConfiguration_relationshipOwnerStrategy_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_GenericRelationshipMatrixCellEditorConfiguration_relationshipOwnerStrategy_feature", "_UI_GenericRelationshipMatrixCellEditorConfiguration_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_STRATEGY,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
+ null,
+ null));
}
/**
@@ -188,13 +190,13 @@ public class GenericRelationshipMatrixCellEditorConfigurationItemProvider extend
* {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- *
* @generated
*/
@Override
public Collection<? extends EStructuralFeature> getChildrenFeatures(Object object) {
if (childrenFeatures == null) {
super.getChildrenFeatures(object);
+ childrenFeatures.add(NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__CELL_CONTENTS_FILTER);
childrenFeatures.add(NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER);
childrenFeatures.add(NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE);
}
@@ -204,7 +206,6 @@ public class GenericRelationshipMatrixCellEditorConfigurationItemProvider extend
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- *
* @generated
*/
@Override
@@ -219,7 +220,6 @@ public class GenericRelationshipMatrixCellEditorConfigurationItemProvider extend
* This returns GenericRelationshipMatrixCellEditorConfiguration.gif.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- *
* @generated
*/
@Override
@@ -230,7 +230,6 @@ public class GenericRelationshipMatrixCellEditorConfigurationItemProvider extend
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- *
* @generated
*/
@Override
@@ -242,14 +241,14 @@ public class GenericRelationshipMatrixCellEditorConfigurationItemProvider extend
* This returns the label text for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- *
* @generated
*/
@Override
public String getText(Object object) {
- String label = ((GenericRelationshipMatrixCellEditorConfiguration) object).getCellEditorId();
- return label == null || label.length() == 0 ? getString("_UI_GenericRelationshipMatrixCellEditorConfiguration_type") : //$NON-NLS-1$
- getString("_UI_GenericRelationshipMatrixCellEditorConfiguration_type") + " " + label; //$NON-NLS-1$ //$NON-NLS-2$
+ String label = ((GenericRelationshipMatrixCellEditorConfiguration)object).getCellEditorId();
+ return label == null || label.length() == 0 ?
+ getString("_UI_GenericRelationshipMatrixCellEditorConfiguration_type") : //$NON-NLS-1$
+ getString("_UI_GenericRelationshipMatrixCellEditorConfiguration_type") + " " + label; //$NON-NLS-1$ //$NON-NLS-2$
}
@@ -258,7 +257,6 @@ public class GenericRelationshipMatrixCellEditorConfigurationItemProvider extend
* children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- *
* @generated
*/
@Override
@@ -266,15 +264,16 @@ public class GenericRelationshipMatrixCellEditorConfigurationItemProvider extend
updateChildren(notification);
switch (notification.getFeatureID(GenericRelationshipMatrixCellEditorConfiguration.class)) {
- case NattablecelleditorPackage.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__CELL_EDITOR_ID:
- case NattablecelleditorPackage.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__DIRECTION:
- case NattablecelleditorPackage.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_STRATEGY:
- fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
- return;
- case NattablecelleditorPackage.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER:
- case NattablecelleditorPackage.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE:
- fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
- return;
+ case NattablecelleditorPackage.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__CELL_EDITOR_ID:
+ case NattablecelleditorPackage.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__DIRECTION:
+ case NattablecelleditorPackage.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_STRATEGY:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
+ return;
+ case NattablecelleditorPackage.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__CELL_CONTENTS_FILTER:
+ case NattablecelleditorPackage.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER:
+ case NattablecelleditorPackage.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
+ return;
}
super.notifyChanged(notification);
}
@@ -284,65 +283,121 @@ public class GenericRelationshipMatrixCellEditorConfigurationItemProvider extend
* that can be created under this object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- *
* @generated
*/
@Override
protected void collectNewChildDescriptors(Collection<Object> newChildDescriptors, Object object) {
super.collectNewChildDescriptors(newChildDescriptors, object);
- newChildDescriptors.add(createChildParameter(NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER,
- NattablewrapperFactory.eINSTANCE.createEObjectWrapper()));
-
- newChildDescriptors.add(createChildParameter(NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER,
- NattablewrapperFactory.eINSTANCE.createIdWrapper()));
-
- newChildDescriptors.add(createChildParameter(NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE,
- NattableaxisFactory.eINSTANCE.createIdTreeItemAxis()));
-
- newChildDescriptors.add(createChildParameter(NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE,
- NattableaxisFactory.eINSTANCE.createEObjectAxis()));
-
- newChildDescriptors.add(createChildParameter(NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE,
- NattableaxisFactory.eINSTANCE.createEObjectTreeItemAxis()));
-
- newChildDescriptors.add(createChildParameter(NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE,
- NattableaxisFactory.eINSTANCE.createFeatureIdAxis()));
-
- newChildDescriptors.add(createChildParameter(NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE,
- NattableaxisFactory.eINSTANCE.createFeatureIdTreeItemAxis()));
-
- newChildDescriptors.add(createChildParameter(NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE,
- NattableaxisFactory.eINSTANCE.createEStructuralFeatureAxis()));
-
- newChildDescriptors.add(createChildParameter(NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE,
- NattableaxisFactory.eINSTANCE.createEOperationAxis()));
-
- newChildDescriptors.add(createChildParameter(NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE,
- NattableaxisFactory.eINSTANCE.createEStructuralFeatureTreeItemAxis()));
-
- newChildDescriptors.add(createChildParameter(NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE,
- NattableaxisFactory.eINSTANCE.createEOperationTreeItemAxis()));
-
- newChildDescriptors.add(createChildParameter(NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE,
- NattableaxisFactory.eINSTANCE.createObjectIdAxis()));
-
- newChildDescriptors.add(createChildParameter(NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE,
- NattableaxisFactory.eINSTANCE.createObjectIdTreeItemAxis()));
-
- newChildDescriptors.add(createChildParameter(NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE,
- NattableaxisFactory.eINSTANCE.createAxisGroup()));
+ newChildDescriptors.add
+ (createChildParameter
+ (NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__CELL_CONTENTS_FILTER,
+ BooleanExpressionsFactory.eINSTANCE.createOrExpression()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__CELL_CONTENTS_FILTER,
+ BooleanExpressionsFactory.eINSTANCE.createAndExpression()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__CELL_CONTENTS_FILTER,
+ BooleanExpressionsFactory.eINSTANCE.createNotExpression()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__CELL_CONTENTS_FILTER,
+ BooleanExpressionsFactory.eINSTANCE.createLiteralTrueExpression()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__CELL_CONTENTS_FILTER,
+ BooleanExpressionsFactory.eINSTANCE.createLiteralFalseExpression()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__CELL_CONTENTS_FILTER,
+ BooleanExpressionsFactory.eINSTANCE.createReferenceBooleanExpression()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER,
+ NattablewrapperFactory.eINSTANCE.createEObjectWrapper()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER,
+ NattablewrapperFactory.eINSTANCE.createIdWrapper()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE,
+ NattableaxisFactory.eINSTANCE.createIdTreeItemAxis()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE,
+ NattableaxisFactory.eINSTANCE.createEObjectAxis()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE,
+ NattableaxisFactory.eINSTANCE.createEObjectTreeItemAxis()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE,
+ NattableaxisFactory.eINSTANCE.createFeatureIdAxis()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE,
+ NattableaxisFactory.eINSTANCE.createFeatureIdTreeItemAxis()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE,
+ NattableaxisFactory.eINSTANCE.createEStructuralFeatureAxis()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE,
+ NattableaxisFactory.eINSTANCE.createEOperationAxis()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE,
+ NattableaxisFactory.eINSTANCE.createEStructuralFeatureTreeItemAxis()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE,
+ NattableaxisFactory.eINSTANCE.createEOperationTreeItemAxis()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE,
+ NattableaxisFactory.eINSTANCE.createObjectIdAxis()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE,
+ NattableaxisFactory.eINSTANCE.createObjectIdTreeItemAxis()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (NattablecelleditorPackage.Literals.GENERIC_RELATIONSHIP_MATRIX_CELL_EDITOR_CONFIGURATION__RELATIONSHIP_OWNER_FEATURE,
+ NattableaxisFactory.eINSTANCE.createAxisGroup()));
}
/**
* Return the resource locator for this item provider's resources.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- *
* @generated
*/
@Override
public ResourceLocator getResourceLocator() {
- return ((IChildCreationExtender) adapterFactory).getResourceLocator();
+ return ((IChildCreationExtender)adapterFactory).getResourceLocator();
}
}
diff --git a/plugins/infra/nattable/org.eclipse.papyrus.infra.nattable.model.edit/src/org/eclipse/papyrus/internal/infra/nattable/model/nattable/nattableaxisconfiguration/provider/ExtendedBooleanEObjectExpressionChildCreationExtender.java b/plugins/infra/nattable/org.eclipse.papyrus.infra.nattable.model.edit/src/org/eclipse/papyrus/internal/infra/nattable/model/nattable/nattableaxisconfiguration/provider/ExtendedBooleanEObjectExpressionChildCreationExtender.java
index a33febdbae1..9273cbac44e 100755
--- a/plugins/infra/nattable/org.eclipse.papyrus.infra.nattable.model.edit/src/org/eclipse/papyrus/internal/infra/nattable/model/nattable/nattableaxisconfiguration/provider/ExtendedBooleanEObjectExpressionChildCreationExtender.java
+++ b/plugins/infra/nattable/org.eclipse.papyrus.infra.nattable.model.edit/src/org/eclipse/papyrus/internal/infra/nattable/model/nattable/nattableaxisconfiguration/provider/ExtendedBooleanEObjectExpressionChildCreationExtender.java
@@ -20,6 +20,7 @@ import java.util.List;
import org.eclipse.emf.common.util.ResourceLocator;
import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.ecore.EObject;
+import org.eclipse.emf.ecore.EStructuralFeature;
import org.eclipse.emf.edit.command.CommandParameter;
import org.eclipse.emf.edit.domain.EditingDomain;
import org.eclipse.emf.edit.provider.IChildCreationExtender;
@@ -29,6 +30,7 @@ import org.eclipse.papyrus.infra.emf.expressions.booleanexpressions.provider.Boo
import org.eclipse.papyrus.infra.nattable.model.nattable.nattableaxisconfiguration.NattableaxisconfigurationPackage;
import org.eclipse.papyrus.infra.nattable.model.nattable.nattableaxisconfiguration.TreeFillingConfiguration;
import org.eclipse.papyrus.infra.nattable.model.nattable.nattablecelleditor.GenericRelationshipMatrixCellEditorConfiguration;
+import org.eclipse.papyrus.infra.nattable.model.nattable.nattablecelleditor.NattablecelleditorPackage;
import org.eclipse.papyrus.infra.nattable.model.nattable.provider.NattableEditPlugin;
public class ExtendedBooleanEObjectExpressionChildCreationExtender implements IChildCreationExtender {
@@ -54,14 +56,15 @@ public class ExtendedBooleanEObjectExpressionChildCreationExtender implements IC
public Collection<?> getNewChildDescriptors(final Object object, final EditingDomain editingDomain) {
Collection<CommandParameter> result = new ArrayList<CommandParameter>();
if (object instanceof TreeFillingConfiguration || object instanceof GenericRelationshipMatrixCellEditorConfiguration) {
-
+ final EStructuralFeature editedFeature = object instanceof TreeFillingConfiguration ? NattableaxisconfigurationPackage.eINSTANCE.getTreeFillingConfiguration_FilterRule()
+ : NattablecelleditorPackage.eINSTANCE.getGenericRelationshipMatrixCellEditorConfiguration_CellContentsFilter();
// for an unknown reason, we get the contribution twice, so I manage it only the first time, identified by its EClass
final List<EClass> alreadyManaged = new ArrayList<EClass>();
- for (final Object curr : expressionsExtendedChildrenFactory.getNewChildDescriptors(this.dummyExpression, editingDomain)) {
+ for (final Object curr : this.expressionsExtendedChildrenFactory.getNewChildDescriptors(this.dummyExpression, editingDomain)) {
if (curr instanceof CommandParameter) {
final EObject value = ((CommandParameter) curr).getEValue();
if (false == alreadyManaged.contains(value.eClass())) {
- final CommandParameter cp = new CommandParameter(null, NattableaxisconfigurationPackage.eINSTANCE.getTreeFillingConfiguration_FilterRule(), value);
+ final CommandParameter cp = new CommandParameter(null, editedFeature, value);
alreadyManaged.add(value.eClass());
result.add(cp);
}
diff --git a/plugins/infra/nattable/org.eclipse.papyrus.infra.nattable.model/model/nattable.genmodel b/plugins/infra/nattable/org.eclipse.papyrus.infra.nattable.model/model/nattable.genmodel
index 68d323119ad..124fce0c915 100644
--- a/plugins/infra/nattable/org.eclipse.papyrus.infra.nattable.model/model/nattable.genmodel
+++ b/plugins/infra/nattable/org.eclipse.papyrus.infra.nattable.model/model/nattable.genmodel
@@ -346,15 +346,27 @@
<genEnumLiterals ecoreEnumLiteral="nattable.ecore#//nattablecelleditor/MatrixRelationShipDirection/FROM_ROW_TO_COLUMN"/>
<genEnumLiterals ecoreEnumLiteral="nattable.ecore#//nattablecelleditor/MatrixRelationShipDirection/FROM_COLUMN_TO_ROW"/>
</genEnums>
+ <genEnums typeSafeEnumCompatible="false" ecoreEnum="nattable.ecore#//nattablecelleditor/MatrixRelationShipOwnerStrategy">
+ <genEnumLiterals ecoreEnumLiteral="nattable.ecore#//nattablecelleditor/MatrixRelationShipOwnerStrategy/DEFAULT"/>
+ <genEnumLiterals ecoreEnumLiteral="nattable.ecore#//nattablecelleditor/MatrixRelationShipOwnerStrategy/TABLE_CONTEXT"/>
+ <genEnumLiterals ecoreEnumLiteral="nattable.ecore#//nattablecelleditor/MatrixRelationShipOwnerStrategy/ROW_OWNER"/>
+ <genEnumLiterals ecoreEnumLiteral="nattable.ecore#//nattablecelleditor/MatrixRelationShipOwnerStrategy/ROW_AS_OWNER"/>
+ <genEnumLiterals ecoreEnumLiteral="nattable.ecore#//nattablecelleditor/MatrixRelationShipOwnerStrategy/COLUMN_OWNER"/>
+ <genEnumLiterals ecoreEnumLiteral="nattable.ecore#//nattablecelleditor/MatrixRelationShipOwnerStrategy/COLUMN_AS_OWNER"/>
+ <genEnumLiterals ecoreEnumLiteral="nattable.ecore#//nattablecelleditor/MatrixRelationShipOwnerStrategy/OTHER"/>
+ </genEnums>
<genClasses image="false" ecoreClass="nattable.ecore#//nattablecelleditor/ICellEditorConfiguration">
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute nattable.ecore#//nattablecelleditor/ICellEditorConfiguration/cellEditorId"/>
</genClasses>
<genClasses ecoreClass="nattable.ecore#//nattablecelleditor/GenericRelationshipMatrixCellEditorConfiguration">
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute nattable.ecore#//nattablecelleditor/GenericRelationshipMatrixCellEditorConfiguration/direction"/>
- <genFeatures notify="false" createChild="false" propertySortChoices="true"
+ <genFeatures children="true" createChild="true" propertySortChoices="true"
ecoreFeature="ecore:EReference nattable.ecore#//nattablecelleditor/GenericRelationshipMatrixCellEditorConfiguration/cellContentsFilter"/>
<genFeatures notify="false" createChild="false" propertySortChoices="true"
ecoreFeature="ecore:EReference nattable.ecore#//nattablecelleditor/GenericRelationshipMatrixCellEditorConfiguration/editedElement"/>
+ <genFeatures createChild="false" ecoreFeature="ecore:EAttribute nattable.ecore#//nattablecelleditor/GenericRelationshipMatrixCellEditorConfiguration/relationshipOwnerStrategy"/>
+ <genFeatures property="None" children="true" createChild="true" ecoreFeature="ecore:EReference nattable.ecore#//nattablecelleditor/GenericRelationshipMatrixCellEditorConfiguration/relationshipOwner"/>
+ <genFeatures property="None" children="true" createChild="true" ecoreFeature="ecore:EReference nattable.ecore#//nattablecelleditor/GenericRelationshipMatrixCellEditorConfiguration/relationshipOwnerFeature"/>
</genClasses>
<genClasses image="false" ecoreClass="nattable.ecore#//nattablecelleditor/IMatrixCellEditorConfiguration"/>
</nestedGenPackages>

Back to the top