diff options
Diffstat (limited to 'plugins/infra/filters')
40 files changed, 1692 insertions, 226 deletions
diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/.classpath b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/.classpath index 664b52ed755..abaf32b3e99 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/.classpath +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/.classpath @@ -1,6 +1,6 @@ <?xml version="1.0" encoding="UTF-8"?> <classpath> - <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/> + <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-17"/> <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/> <classpathentry kind="src" path="src-gen"/> <classpathentry kind="output" path="bin"/> diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/.settings/org.eclipse.jdt.core.prefs b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/.settings/org.eclipse.jdt.core.prefs index 19dd3450bfd..a8cc7ef70ef 100644..100755 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/.settings/org.eclipse.jdt.core.prefs +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/.settings/org.eclipse.jdt.core.prefs @@ -1,17 +1,20 @@ eclipse.preferences.version=1 org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7 +org.eclipse.jdt.core.compiler.codegen.targetPlatform=17 org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve -org.eclipse.jdt.core.compiler.compliance=1.7 +org.eclipse.jdt.core.compiler.compliance=17 org.eclipse.jdt.core.compiler.debug.lineNumber=generate org.eclipse.jdt.core.compiler.debug.localVariable=generate org.eclipse.jdt.core.compiler.debug.sourceFile=generate org.eclipse.jdt.core.compiler.problem.assertIdentifier=error +org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.release=disabled -org.eclipse.jdt.core.compiler.source=1.7 +org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning +org.eclipse.jdt.core.compiler.release=enabled +org.eclipse.jdt.core.compiler.source=17 org.eclipse.jdt.core.formatter.align_type_members_on_columns=false +org.eclipse.jdt.core.formatter.alignment_for_additive_operator=16 org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16 org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0 org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16 @@ -19,17 +22,20 @@ org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_c org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16 org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16 org.eclipse.jdt.core.formatter.alignment_for_assignment=0 -org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16 +org.eclipse.jdt.core.formatter.alignment_for_bitwise_operator=16 org.eclipse.jdt.core.formatter.alignment_for_compact_if=16 org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80 org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0 org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16 +org.eclipse.jdt.core.formatter.alignment_for_logical_operator=16 org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0 org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16 +org.eclipse.jdt.core.formatter.alignment_for_multiplicative_operator=16 org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16 org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16 org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80 org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=16 +org.eclipse.jdt.core.formatter.alignment_for_string_concatenation=16 org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16 org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16 org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16 @@ -115,11 +121,12 @@ org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_after_additive_operator=insert org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert -org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert +org.eclipse.jdt.core.formatter.insert_space_after_bitwise_operator=insert org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert @@ -150,6 +157,8 @@ org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert org.eclipse.jdt.core.formatter.insert_space_after_lambda_arrow=insert +org.eclipse.jdt.core.formatter.insert_space_after_logical_operator=insert +org.eclipse.jdt.core.formatter.insert_space_after_multiplicative_operator=insert org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert @@ -174,13 +183,17 @@ org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_relational_operator=insert org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert +org.eclipse.jdt.core.formatter.insert_space_after_shift_operator=insert +org.eclipse.jdt.core.formatter.insert_space_after_string_concatenation=insert org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_additive_operator=insert org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert -org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert +org.eclipse.jdt.core.formatter.insert_space_before_bitwise_operator=insert org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert @@ -228,6 +241,8 @@ org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do no org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert org.eclipse.jdt.core.formatter.insert_space_before_lambda_arrow=insert +org.eclipse.jdt.core.formatter.insert_space_before_logical_operator=insert +org.eclipse.jdt.core.formatter.insert_space_before_multiplicative_operator=insert org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert @@ -264,9 +279,12 @@ org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not inser org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_relational_operator=insert org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_shift_operator=insert +org.eclipse.jdt.core.formatter.insert_space_before_string_concatenation=insert org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert @@ -292,6 +310,10 @@ org.eclipse.jdt.core.formatter.tabulation.char=tab org.eclipse.jdt.core.formatter.tabulation.size=4 org.eclipse.jdt.core.formatter.use_on_off_tags=false org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false -org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true +org.eclipse.jdt.core.formatter.wrap_before_additive_operator=true +org.eclipse.jdt.core.formatter.wrap_before_bitwise_operator=true +org.eclipse.jdt.core.formatter.wrap_before_logical_operator=true +org.eclipse.jdt.core.formatter.wrap_before_multiplicative_operator=true org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true +org.eclipse.jdt.core.formatter.wrap_before_string_concatenation=true org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/META-INF/MANIFEST.MF b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/META-INF/MANIFEST.MF index c96efa0038c..e70181f80bf 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/META-INF/MANIFEST.MF +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/META-INF/MANIFEST.MF @@ -1,18 +1,18 @@ Manifest-Version: 1.0 Export-Package: org.eclipse.papyrus.infra.filters.provider -Require-Bundle: org.eclipse.core.runtime;bundle-version="[3.12.0,4.0.0)", - org.eclipse.papyrus.infra.filters;bundle-version="[1.2.0,2.0.0)";visibility:=reexport, - org.eclipse.emf.edit;bundle-version="[2.11.0,3.0.0)";visibility:=reexport, - org.eclipse.uml2.types;bundle-version="[2.0.0,3.0.0)";visibility:=reexport, - org.eclipse.uml2.common.edit;bundle-version="[2.1.0,3.0.0)";visibility:=reexport +Require-Bundle: org.eclipse.core.runtime;bundle-version="[3.18.0,4.0.0)", + org.eclipse.papyrus.infra.filters;bundle-version="[2.0.0,3.0.0)";visibility:=reexport, + org.eclipse.emf.edit;bundle-version="[2.16.0,3.0.0)", + org.eclipse.uml2.common.edit;bundle-version="[2.5.0,3.0.0)", + org.eclipse.uml2.types;bundle-version="[2.5.0,3.0.0)" Bundle-Vendor: %providerName Bundle-ActivationPolicy: lazy Bundle-ClassPath: . -Bundle-Version: 1.4.0.qualifier +Bundle-Version: 2.0.0.qualifier Bundle-Name: %pluginName Bundle-Localization: plugin Bundle-ManifestVersion: 2 Bundle-Activator: org.eclipse.papyrus.infra.filters.provider.FiltersEditPlugin$Implementation Bundle-SymbolicName: org.eclipse.papyrus.infra.filters.edit;singleton:=true -Bundle-RequiredExecutionEnvironment: JavaSE-1.7 +Bundle-RequiredExecutionEnvironment: JavaSE-17 Automatic-Module-Name: org.eclipse.papyrus.infra.filters.edit diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/icons/full/obj16/Equals.gif b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/icons/full/obj16/Equals.gif Binary files differindex 9250fecbffd..dc514c8c851 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/icons/full/obj16/Equals.gif +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/icons/full/obj16/Equals.gif diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/icons/full/obj16/Equals@2x.gif b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/icons/full/obj16/Equals@2x.gif Binary files differnew file mode 100644 index 00000000000..6ee84b24b9c --- /dev/null +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/icons/full/obj16/Equals@2x.gif diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/icons/full/obj16/FilterReference.gif b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/icons/full/obj16/FilterReference.gif Binary files differnew file mode 100644 index 00000000000..920b69ce9c9 --- /dev/null +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/icons/full/obj16/FilterReference.gif diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/icons/full/obj16/FilterReference@2x.gif b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/icons/full/obj16/FilterReference@2x.gif Binary files differnew file mode 100644 index 00000000000..63a9bd3b577 --- /dev/null +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/icons/full/obj16/FilterReference@2x.gif diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/plugin.properties b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/plugin.properties index 2d6e1ae3c27..abfac7b7e2d 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/plugin.properties +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/plugin.properties @@ -1,4 +1,4 @@ -# Copyright (c) 2014 Christian W. Damus and others. +# Copyright (c) 2014, 2021 Christian W. Damus, CEA LIST, and others. # # All rights reserved. This program and the accompanying materials # are made available under the terms of the Eclipse Public License 2.0 @@ -24,6 +24,7 @@ _UI_PropertyDescriptor_description = The {0} of the {1} _UI_Filter_type = Filter _UI_CompoundFilter_type = Compound Filter +_UI_CompoundFilter_type_pattern = {0} Filter _UI_Unknown_type = Object _UI_Unknown_datatype= Value @@ -34,11 +35,14 @@ _UI_CompoundFilter_ownedFilter_feature = Owned Filter _UI_CompoundFilter_operator_feature = Operator _UI_Unknown_feature = Unspecified -_UI_OperatorKind_and_literal = and -_UI_OperatorKind_or_literal = or -_UI_OperatorKind_xor_literal = xor -_UI_OperatorKind_not_literal = not +_UI_OperatorKind_and_literal = And +_UI_OperatorKind_or_literal = Or +_UI_OperatorKind_xor_literal = Xor +_UI_OperatorKind_not_literal = Not _UI_Equals_type = Equals _UI_Equals_object_feature = Object _UI_FilteredElement_type = Filtered Element _UI_FilteredElement_filter_feature = Filter +_UI_FilterReference_type = Filter Reference +_UI_FilterReference_filter_feature = Filter +_UI_FilterReference_ownedFilter_feature = Owned Filter diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/pom.xml b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/pom.xml index 5479b151ab3..d75214a600c 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/pom.xml +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/pom.xml @@ -1,5 +1,6 @@ <?xml version="1.0" encoding="UTF-8"?> -<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" +<project xmlns="http://maven.apache.org/POM/4.0.0" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> <parent> @@ -8,6 +9,6 @@ <version>0.0.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.papyrus.infra.filters.edit</artifactId> - <version>1.4.0-SNAPSHOT</version> + <version>2.0.0-SNAPSHOT</version> <packaging>eclipse-plugin</packaging> -</project> +</project>
\ No newline at end of file diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/src-gen/org/eclipse/papyrus/infra/filters/provider/CompoundFilterItemProvider.java b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/src-gen/org/eclipse/papyrus/infra/filters/provider/CompoundFilterItemProvider.java index e8412e7ea51..1df0871f92e 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/src-gen/org/eclipse/papyrus/infra/filters/provider/CompoundFilterItemProvider.java +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/src-gen/org/eclipse/papyrus/infra/filters/provider/CompoundFilterItemProvider.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2014 Christian W. Damus and others. + * Copyright (c) 2014, 2021 Christian W. Damus, CEA LIST, and others. * * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License 2.0 @@ -16,6 +16,7 @@ package org.eclipse.papyrus.infra.filters.provider; import java.util.Collection; import java.util.List; + import org.eclipse.emf.common.command.Command; import org.eclipse.emf.common.notify.AdapterFactory; import org.eclipse.emf.common.notify.Notification; @@ -37,6 +38,7 @@ import org.eclipse.emf.edit.provider.ViewerNotification; import org.eclipse.papyrus.infra.filters.CompoundFilter; import org.eclipse.papyrus.infra.filters.FiltersFactory; import org.eclipse.papyrus.infra.filters.FiltersPackage; +import org.eclipse.papyrus.infra.filters.OperatorKind; import org.eclipse.uml2.common.edit.command.SubsetAddCommand; import org.eclipse.uml2.common.edit.command.SubsetSupersetReplaceCommand; import org.eclipse.uml2.common.edit.command.SubsetSupersetSetCommand; @@ -204,13 +206,27 @@ public class CompoundFilterItemProvider extends ItemProviderAdapter implements I * <!-- begin-user-doc --> * <!-- end-user-doc --> * - * @generated + * @generated NOT */ @Override public String getText(Object object) { - String label = ((CompoundFilter) object).getName(); - return label == null || label.length() == 0 ? getString("_UI_CompoundFilter_type") : //$NON-NLS-1$ - getString("_UI_CompoundFilter_type") + " " + label; //$NON-NLS-1$ //$NON-NLS-2$ + StringBuilder result = new StringBuilder(); + CompoundFilter compound = (CompoundFilter) object; + + OperatorKind operator = compound.getOperator(); + if (operator == null) { + result.append(getString("_UI_CompoundFilter_type")); //$NON-NLS-1$ + } else { + result.append(getString("_UI_CompoundFilter_type_pattern", String.format("_UI_OperatorKind_%s_literal", operator.getLiteral()))); //$NON-NLS-1$//$NON-NLS-2$ + } + + String label = compound.getName(); + if (label != null && !label.isBlank()) { + result.append(" "); //$NON-NLS-1$ + result.append(label); + } + + return result.toString(); } @@ -252,6 +268,9 @@ public class CompoundFilterItemProvider extends ItemProviderAdapter implements I super.collectNewChildDescriptors(newChildDescriptors, object); newChildDescriptors.add(createChildParameter(FiltersPackage.Literals.COMPOUND_FILTER__OWNED_FILTER, + FiltersFactory.eINSTANCE.createFilterReference())); + + newChildDescriptors.add(createChildParameter(FiltersPackage.Literals.COMPOUND_FILTER__OWNED_FILTER, FiltersFactory.eINSTANCE.createCompoundFilter())); newChildDescriptors.add(createChildParameter(FiltersPackage.Literals.COMPOUND_FILTER__OWNED_FILTER, diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/src-gen/org/eclipse/papyrus/infra/filters/provider/FilterReferenceItemProvider.java b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/src-gen/org/eclipse/papyrus/infra/filters/provider/FilterReferenceItemProvider.java new file mode 100644 index 00000000000..45c823b8399 --- /dev/null +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/src-gen/org/eclipse/papyrus/infra/filters/provider/FilterReferenceItemProvider.java @@ -0,0 +1,305 @@ +/** + * Copyright (c) 2021 Christian W. Damus, CEA LIST, and others. + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the Eclipse Public License 2.0 + * which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-2.0/ + * + * SPDX-License-Identifier: EPL-2.0 + * + * Contributors: + * Christian W. Damus - Initial API and implementation + */ +package org.eclipse.papyrus.infra.filters.provider; + + +import java.util.Collection; +import java.util.List; + +import org.eclipse.emf.common.command.Command; +import org.eclipse.emf.common.notify.AdapterFactory; +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.util.ResourceLocator; +import org.eclipse.emf.ecore.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.ComposeableAdapterFactory; +import org.eclipse.emf.edit.provider.IChildCreationExtender; +import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; +import org.eclipse.emf.edit.provider.IItemLabelProvider; +import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; +import org.eclipse.emf.edit.provider.IItemPropertySource; +import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; +import org.eclipse.emf.edit.provider.ITreeItemContentProvider; +import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; +import org.eclipse.emf.edit.provider.ItemProviderAdapter; +import org.eclipse.emf.edit.provider.ViewerNotification; +import org.eclipse.papyrus.infra.filters.Filter; +import org.eclipse.papyrus.infra.filters.FilterReference; +import org.eclipse.papyrus.infra.filters.FiltersFactory; +import org.eclipse.papyrus.infra.filters.FiltersPackage; +import org.eclipse.uml2.common.edit.command.SubsetSupersetSetCommand; + +/** + * This is the item provider adapter for a {@link org.eclipse.papyrus.infra.filters.FilterReference} object. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ +public class FilterReferenceItemProvider + extends ItemProviderAdapter + implements + IEditingDomainItemProvider, + IStructuredItemContentProvider, + ITreeItemContentProvider, + IItemLabelProvider, + IItemPropertySource { + /** + * This constructs an instance from a factory and a notifier. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + public FilterReferenceItemProvider(AdapterFactory adapterFactory) { + super(adapterFactory); + } + + /** + * This returns the property descriptors for the adapted class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override + public List<IItemPropertyDescriptor> getPropertyDescriptors(Object object) { + if (itemPropertyDescriptors == null) { + super.getPropertyDescriptors(object); + + addNamePropertyDescriptor(object); + addFilterPropertyDescriptor(object); + } + return itemPropertyDescriptors; + } + + /** + * This adds a property descriptor for the Name feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + protected void addNamePropertyDescriptor(Object object) { + itemPropertyDescriptors.add(createItemPropertyDescriptor(((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(), + getResourceLocator(), + getString("_UI_Filter_name_feature"), //$NON-NLS-1$ + getString("_UI_PropertyDescriptor_description", "_UI_Filter_name_feature", "_UI_Filter_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ + FiltersPackage.Literals.FILTER__NAME, + true, + false, + false, + ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, + null, + null)); + } + + /** + * This adds a property descriptor for the Filter feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + protected void addFilterPropertyDescriptor(Object object) { + itemPropertyDescriptors.add(createItemPropertyDescriptor(((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(), + getResourceLocator(), + getString("_UI_FilterReference_filter_feature"), //$NON-NLS-1$ + getString("_UI_PropertyDescriptor_description", "_UI_FilterReference_filter_feature", "_UI_FilterReference_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ + FiltersPackage.Literals.FILTER_REFERENCE__FILTER, + true, + false, + true, + null, + null, + null)); + } + + /** + * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an + * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or + * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override + public Collection<? extends EStructuralFeature> getChildrenFeatures(Object object) { + if (childrenFeatures == null) { + super.getChildrenFeatures(object); + childrenFeatures.add(FiltersPackage.Literals.FILTER_REFERENCE__OWNED_FILTER); + } + return childrenFeatures; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @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 FilterReference.gif. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override + public Object getImage(Object object) { + return overlayImage(object, getResourceLocator().getImage("full/obj16/FilterReference")); //$NON-NLS-1$ + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override + protected boolean shouldComposeCreationImage() { + return true; + } + + /** + * This returns the label text for the adapted class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated NOT + */ + @Override + public String getText(Object object) { + StringBuilder result = new StringBuilder(); + FilterReference filterReference = (FilterReference) object; + + result.append(getString("_UI_FilterReference_type")); //$NON-NLS-1$ + + String label = filterReference.getName(); + if (label != null && !label.isBlank()) { + result.append(" "); //$NON-NLS-1$ + result.append(label); + } + + Filter reference = filterReference.getFilter(); + if (reference != null) { + String referenceLabel = null; + IItemLabelProvider provider = (IItemLabelProvider) getRootAdapterFactory().adapt(reference, IItemLabelProvider.class); + if (provider != null) { + referenceLabel = provider.getText(reference); + } + if (referenceLabel != null && !referenceLabel.isBlank()) { + result.append(" -> "); //$NON-NLS-1$ + result.append(referenceLabel); + } + } + + return result.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}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override + public void notifyChanged(Notification notification) { + updateChildren(notification); + + switch (notification.getFeatureID(FilterReference.class)) { + case FiltersPackage.FILTER_REFERENCE__NAME: + case FiltersPackage.FILTER_REFERENCE__FILTER: + fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); + return; + case FiltersPackage.FILTER_REFERENCE__OWNED_FILTER: + fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false)); + return; + } + super.notifyChanged(notification); + } + + /** + * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children + * that can be created under this object. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + protected void collectNewChildDescriptorsGen(Collection<Object> newChildDescriptors, Object object) { + super.collectNewChildDescriptors(newChildDescriptors, object); + + newChildDescriptors.add(createChildParameter(FiltersPackage.Literals.FILTER_REFERENCE__OWNED_FILTER, + FiltersFactory.eINSTANCE.createFilterReference())); + + newChildDescriptors.add(createChildParameter(FiltersPackage.Literals.FILTER_REFERENCE__OWNED_FILTER, + FiltersFactory.eINSTANCE.createCompoundFilter())); + + newChildDescriptors.add(createChildParameter(FiltersPackage.Literals.FILTER_REFERENCE__OWNED_FILTER, + FiltersFactory.eINSTANCE.createEquals())); + } + + @Override + protected void collectNewChildDescriptors(Collection<Object> newChildDescriptors, Object object) { + collectNewChildDescriptorsGen(newChildDescriptors, object); + + // It seems pointless to create a filter reference owned by a filter reference + newChildDescriptors.removeIf(descriptor -> descriptor instanceof CommandParameter && ((CommandParameter) descriptor).getValue() instanceof FilterReference); + } + + /** + * 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(); + } + + /** + * @see org.eclipse.emf.edit.provider.ItemProviderAdapter#createSetCommand(org.eclipse.emf.edit.domain.EditingDomain, org.eclipse.emf.ecore.EObject, org.eclipse.emf.ecore.EStructuralFeature, java.lang.Object) + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected Command createSetCommand(EditingDomain domain, EObject owner, EStructuralFeature feature, Object value) { + if (feature == FiltersPackage.Literals.FILTER_REFERENCE__OWNED_FILTER) { + return new SubsetSupersetSetCommand(domain, owner, feature, new EStructuralFeature[] { FiltersPackage.Literals.FILTER_REFERENCE__FILTER }, null, value); + } + if (feature == FiltersPackage.Literals.FILTER_REFERENCE__FILTER) { + return new SubsetSupersetSetCommand(domain, owner, feature, null, new EStructuralFeature[] { FiltersPackage.Literals.FILTER_REFERENCE__OWNED_FILTER }, value); + } + return super.createSetCommand(domain, owner, feature, value); + } + +} diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/src-gen/org/eclipse/papyrus/infra/filters/provider/FilteredElementItemProvider.java b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/src-gen/org/eclipse/papyrus/infra/filters/provider/FilteredElementItemProvider.java index d22d166518c..ea93733b116 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/src-gen/org/eclipse/papyrus/infra/filters/provider/FilteredElementItemProvider.java +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/src-gen/org/eclipse/papyrus/infra/filters/provider/FilteredElementItemProvider.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2014 Christian W. Damus and others. + * Copyright (c) 2014, 2021 Christian W. Damus, CEA LIST, and others. * * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License 2.0 @@ -44,7 +44,6 @@ import org.eclipse.papyrus.infra.filters.FiltersPackage; * <!-- end-user-doc --> * * @generated - * @since 1.4 */ public class FilteredElementItemProvider extends ItemProviderAdapter @@ -170,6 +169,9 @@ public class FilteredElementItemProvider super.collectNewChildDescriptors(newChildDescriptors, object); newChildDescriptors.add(createChildParameter(FiltersPackage.Literals.FILTERED_ELEMENT__FILTER, + FiltersFactory.eINSTANCE.createFilterReference())); + + newChildDescriptors.add(createChildParameter(FiltersPackage.Literals.FILTERED_ELEMENT__FILTER, FiltersFactory.eINSTANCE.createCompoundFilter())); newChildDescriptors.add(createChildParameter(FiltersPackage.Literals.FILTERED_ELEMENT__FILTER, diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/src-gen/org/eclipse/papyrus/infra/filters/provider/FiltersItemProviderAdapterFactory.java b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/src-gen/org/eclipse/papyrus/infra/filters/provider/FiltersItemProviderAdapterFactory.java index f1996cce2cb..9bb66f50488 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/src-gen/org/eclipse/papyrus/infra/filters/provider/FiltersItemProviderAdapterFactory.java +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters.edit/src-gen/org/eclipse/papyrus/infra/filters/provider/FiltersItemProviderAdapterFactory.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2014 Christian W. Damus and others. + * Copyright (c) 2014, 2021 Christian W. Damus, CEA LIST, and others. * * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License 2.0 @@ -159,7 +159,6 @@ public class FiltersItemProviderAdapterFactory extends FiltersAdapterFactory imp * <!-- end-user-doc --> * * @generated - * @since 1.4 */ protected FilteredElementItemProvider filteredElementItemProvider; @@ -180,6 +179,31 @@ public class FiltersItemProviderAdapterFactory extends FiltersAdapterFactory imp } /** + * This keeps track of the one adapter used for all {@link org.eclipse.papyrus.infra.filters.FilterReference} instances. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + protected FilterReferenceItemProvider filterReferenceItemProvider; + + /** + * This creates an adapter for a {@link org.eclipse.papyrus.infra.filters.FilterReference}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override + public Adapter createFilterReferenceAdapter() { + if (filterReferenceItemProvider == null) { + filterReferenceItemProvider = new FilterReferenceItemProvider(this); + } + + return filterReferenceItemProvider; + } + + /** * This returns the root adapter factory that contains this factory. * <!-- begin-user-doc --> * <!-- end-user-doc --> @@ -325,6 +349,9 @@ public class FiltersItemProviderAdapterFactory extends FiltersAdapterFactory imp */ @Override public void dispose() { + if (filterReferenceItemProvider != null) { + filterReferenceItemProvider.dispose(); + } if (compoundFilterItemProvider != null) { compoundFilterItemProvider.dispose(); } diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/.classpath b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/.classpath index ca965add0fd..fd01258584d 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/.classpath +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/.classpath @@ -1,6 +1,6 @@ <?xml version="1.0" encoding="UTF-8"?> <classpath> - <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/> + <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-17"/> <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/> <classpathentry kind="src" path="src-gen"/> <classpathentry kind="src" path="src"/> diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/.settings/org.eclipse.jdt.core.prefs b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/.settings/org.eclipse.jdt.core.prefs index 19dd3450bfd..a8cc7ef70ef 100644..100755 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/.settings/org.eclipse.jdt.core.prefs +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/.settings/org.eclipse.jdt.core.prefs @@ -1,17 +1,20 @@ eclipse.preferences.version=1 org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7 +org.eclipse.jdt.core.compiler.codegen.targetPlatform=17 org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve -org.eclipse.jdt.core.compiler.compliance=1.7 +org.eclipse.jdt.core.compiler.compliance=17 org.eclipse.jdt.core.compiler.debug.lineNumber=generate org.eclipse.jdt.core.compiler.debug.localVariable=generate org.eclipse.jdt.core.compiler.debug.sourceFile=generate org.eclipse.jdt.core.compiler.problem.assertIdentifier=error +org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.release=disabled -org.eclipse.jdt.core.compiler.source=1.7 +org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning +org.eclipse.jdt.core.compiler.release=enabled +org.eclipse.jdt.core.compiler.source=17 org.eclipse.jdt.core.formatter.align_type_members_on_columns=false +org.eclipse.jdt.core.formatter.alignment_for_additive_operator=16 org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16 org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0 org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16 @@ -19,17 +22,20 @@ org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_c org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16 org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16 org.eclipse.jdt.core.formatter.alignment_for_assignment=0 -org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16 +org.eclipse.jdt.core.formatter.alignment_for_bitwise_operator=16 org.eclipse.jdt.core.formatter.alignment_for_compact_if=16 org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80 org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0 org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16 +org.eclipse.jdt.core.formatter.alignment_for_logical_operator=16 org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0 org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16 +org.eclipse.jdt.core.formatter.alignment_for_multiplicative_operator=16 org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16 org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16 org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80 org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=16 +org.eclipse.jdt.core.formatter.alignment_for_string_concatenation=16 org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16 org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16 org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16 @@ -115,11 +121,12 @@ org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_after_additive_operator=insert org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert -org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert +org.eclipse.jdt.core.formatter.insert_space_after_bitwise_operator=insert org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert @@ -150,6 +157,8 @@ org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert org.eclipse.jdt.core.formatter.insert_space_after_lambda_arrow=insert +org.eclipse.jdt.core.formatter.insert_space_after_logical_operator=insert +org.eclipse.jdt.core.formatter.insert_space_after_multiplicative_operator=insert org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert @@ -174,13 +183,17 @@ org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_relational_operator=insert org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert +org.eclipse.jdt.core.formatter.insert_space_after_shift_operator=insert +org.eclipse.jdt.core.formatter.insert_space_after_string_concatenation=insert org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_additive_operator=insert org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert -org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert +org.eclipse.jdt.core.formatter.insert_space_before_bitwise_operator=insert org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert @@ -228,6 +241,8 @@ org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do no org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert org.eclipse.jdt.core.formatter.insert_space_before_lambda_arrow=insert +org.eclipse.jdt.core.formatter.insert_space_before_logical_operator=insert +org.eclipse.jdt.core.formatter.insert_space_before_multiplicative_operator=insert org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert @@ -264,9 +279,12 @@ org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not inser org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_relational_operator=insert org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_shift_operator=insert +org.eclipse.jdt.core.formatter.insert_space_before_string_concatenation=insert org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert @@ -292,6 +310,10 @@ org.eclipse.jdt.core.formatter.tabulation.char=tab org.eclipse.jdt.core.formatter.tabulation.size=4 org.eclipse.jdt.core.formatter.use_on_off_tags=false org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false -org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true +org.eclipse.jdt.core.formatter.wrap_before_additive_operator=true +org.eclipse.jdt.core.formatter.wrap_before_bitwise_operator=true +org.eclipse.jdt.core.formatter.wrap_before_logical_operator=true +org.eclipse.jdt.core.formatter.wrap_before_multiplicative_operator=true org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true +org.eclipse.jdt.core.formatter.wrap_before_string_concatenation=true org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/META-INF/MANIFEST.MF b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/META-INF/MANIFEST.MF index b6a2aeca9b7..c7bab7878ed 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/META-INF/MANIFEST.MF +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/META-INF/MANIFEST.MF @@ -1,9 +1,9 @@ Manifest-Version: 1.0 -Require-Bundle: org.eclipse.core.runtime, - org.eclipse.emf.ecore;bundle-version="[2.11.0,3.0.0)";visibility:=reexport, - org.eclipse.uml2.types;bundle-version="[2.0.0,3.0.0)";visibility:=reexport, - org.eclipse.uml2.common;bundle-version="[2.1.0,3.0.0)";visibility:=reexport, - org.eclipse.papyrus.infra.core.log;bundle-version="[1.2.0,2.0.0)" +Require-Bundle: org.eclipse.core.runtime;bundle-version="[3.18.0,4.0.0)", + org.eclipse.emf.ecore;bundle-version="[2.23.0,3.0.0)", + org.eclipse.papyrus.infra.core.log;bundle-version="[2.0.0,3.0.0)", + org.eclipse.uml2.types;bundle-version="[2.5.0,3.0.0)", + org.eclipse.uml2.common;bundle-version="[2.5.0,3.0.0)" Export-Package: org.eclipse.papyrus.infra.filters, org.eclipse.papyrus.infra.filters.impl, org.eclipse.papyrus.infra.filters.internal;x-internal:=true, @@ -12,12 +12,12 @@ Export-Package: org.eclipse.papyrus.infra.filters, Bundle-Vendor: %providerName Bundle-ActivationPolicy: lazy Bundle-ClassPath: . -Bundle-Version: 1.3.0.qualifier +Bundle-Version: 2.0.0.qualifier Bundle-Localization: plugin Bundle-Name: %pluginName Bundle-Activator: org.eclipse.papyrus.infra.filters.internal.FiltersPlugin$Implementation Bundle-ManifestVersion: 2 Bundle-Description: %pluginDescription Bundle-SymbolicName: org.eclipse.papyrus.infra.filters;singleton:=true -Bundle-RequiredExecutionEnvironment: JavaSE-1.7 +Bundle-RequiredExecutionEnvironment: JavaSE-17 Automatic-Module-Name: org.eclipse.papyrus.infra.filters diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/model/filters.ecore b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/model/filters.ecore index ba13dac3e01..acc7c22573a 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/model/filters.ecore +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/model/filters.ecore @@ -2,6 +2,26 @@ <ecore:EPackage xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" name="filters" nsURI="http://www.eclipse.org/Papyrus/2014/common/filters" nsPrefix="filters"> + <eClassifiers xsi:type="ecore:EClass" name="FilterReference" eSuperTypes="#//Filter"> + <eAnnotations source="http://www.eclipse.org/emf/2002/GenModel"> + <details key="documentation" value="A filter that redirects to a referenced filter. Useful to reuse filters by reference in any
context where otherwise the filtered element doesn't support shared filters."/> + </eAnnotations> + <eStructuralFeatures xsi:type="ecore:EReference" name="filter" ordered="false" + lowerBound="1" eType="#//Filter"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="ownedFilter" ordered="false" + eType="#//Filter" containment="true"> + <eAnnotations source="http://www.eclipse.org/emf/2002/GenModel"> + <details key="documentation" value="Owning the indirect reference
lets a dependent model that uses
filters access all available child
creation extenders, when it cannot
access those extenders, itself."/> + </eAnnotations> + <eAnnotations source="subsets" references="#//FilterReference/filter"/> + </eStructuralFeatures> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="Filter" abstract="true" interface="true"> + <eOperations name="matches" ordered="false" lowerBound="1" eType="ecore:EDataType ../../org.eclipse.uml2.types/model/Types.ecore#//Boolean"> + <eParameters name="input" ordered="false" lowerBound="1" eType="#//Object"/> + </eOperations> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="name" ordered="false" eType="ecore:EDataType ../../org.eclipse.uml2.types/model/Types.ecore#//String"/> + </eClassifiers> <eClassifiers xsi:type="ecore:EDataType" name="Object" instanceClassName="java.lang.Object"/> <eClassifiers xsi:type="ecore:EClass" name="CompoundFilter" eSuperTypes="#//Filter"> <eOperations name="acyclic" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EBoolean"> @@ -32,12 +52,6 @@ <eStructuralFeatures xsi:type="ecore:EAttribute" name="operator" ordered="false" lowerBound="1" eType="#//OperatorKind"/> </eClassifiers> - <eClassifiers xsi:type="ecore:EClass" name="Filter" abstract="true" interface="true"> - <eOperations name="matches" ordered="false" lowerBound="1" eType="ecore:EDataType ../../org.eclipse.uml2.types/model/Types.ecore#//Boolean"> - <eParameters name="input" ordered="false" lowerBound="1" eType="#//Object"/> - </eOperations> - <eStructuralFeatures xsi:type="ecore:EAttribute" name="name" ordered="false" eType="ecore:EDataType ../../org.eclipse.uml2.types/model/Types.ecore#//String"/> - </eClassifiers> <eClassifiers xsi:type="ecore:EEnum" name="OperatorKind"> <eLiterals name="and"/> <eLiterals name="or" value="1"/> diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/model/filters.genmodel b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/model/filters.genmodel index 5760702a715..3b4996854fd 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/model/filters.genmodel +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/model/filters.genmodel @@ -1,17 +1,16 @@ <?xml version="1.0" encoding="UTF-8"?> <genmodel:GenModel xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" xmlns:genmodel="http://www.eclipse.org/uml2/2.2.0/GenModel" - copyrightText="Copyright (c) 2014 Christian W. Damus and others.

 All rights reserved. This program and the accompanying materials
 are made available under the terms of the Eclipse Public License 2.0
 which accompanies this distribution, and is available at
 https://www.eclipse.org/legal/epl-2.0/

 SPDX-License-Identifier: EPL-2.0

 Contributors:
 Christian W. Damus - Initial API and implementation" + copyrightText="Copyright (c) 2014, 2021 Christian W. Damus and others.

 All rights reserved. This program and the accompanying materials
 are made available under the terms of the Eclipse Public License 2.0
 which accompanies this distribution, and is available at
 https://www.eclipse.org/legal/epl-2.0/

 SPDX-License-Identifier: EPL-2.0

 Contributors:
 Christian W. Damus - Initial API and implementation" modelDirectory="/org.eclipse.papyrus.infra.filters/src-gen" creationIcons="false" editDirectory="/org.eclipse.papyrus.infra.filters.edit/src-gen" editorDirectory="/org.eclipse.papyrus.infra.filters.editor/src-gen" modelPluginID="org.eclipse.papyrus.infra.filters" modelName="Filters" nonNLSMarkers="true" rootExtendsClass="org.eclipse.emf.ecore.impl.MinimalEObjectImpl$Container" codeFormatting="true" commentFormatting="true" testsDirectory="/org.eclipse.papyrus.infra.filters.tests/src-gen" - booleanFlagsField="_flags" importerID="org.eclipse.uml2.uml.ecore.importer" complianceLevel="7.0" - copyrightFields="false" packedEnums="true" operationReflection="true" importOrganizing="true" - usedGenPackages="../../org.eclipse.uml2.types/model/Types.genmodel#//types" - cleanup="true" factoryMethods="true" pluralizedGetters="true" safeStrings="true" - invariantPrefix="validate"> + booleanFlagsField="_flags" importerID="org.eclipse.uml2.uml.ecore.importer" complianceLevel="11.0" + copyrightFields="false" packedEnums="true" usedGenPackages="../../org.eclipse.uml2.types/model/Types.genmodel#//types" + operationReflection="true" importOrganizing="true" cleanup="true" factoryMethods="true" + pluralizedGetters="true" safeStrings="true" invariantPrefix="validate"> <genAnnotations source="http://www.eclipse.org/emf/2002/GenModel/importer/org.eclipse.uml2.uml.ecore.importer"> <details key="ECORE_TAGGED_VALUES" value="PROCESS"/> <details key="UNION_PROPERTIES" value="PROCESS"/> @@ -47,6 +46,19 @@ <genEnumLiterals xsi:type="genmodel:GenEnumLiteral" ecoreEnumLiteral="filters.ecore#//OperatorKind/not"/> </genEnums> <genDataTypes xsi:type="genmodel:GenDataType" ecoreDataType="filters.ecore#//Object"/> + <genClasses xsi:type="genmodel:GenClass" ecoreClass="filters.ecore#//FilterReference"> + <genFeatures xsi:type="genmodel:GenFeature" createChild="false" propertySortChoices="true" + ecoreFeature="ecore:EReference filters.ecore#//FilterReference/filter"/> + <genFeatures xsi:type="genmodel:GenFeature" property="None" children="true" + createChild="true" ecoreFeature="ecore:EReference filters.ecore#//FilterReference/ownedFilter"/> + </genClasses> + <genClasses xsi:type="genmodel:GenClass" image="false" ecoreClass="filters.ecore#//Filter"> + <genFeatures xsi:type="genmodel:GenFeature" createChild="false" ecoreFeature="ecore:EAttribute filters.ecore#//Filter/name" + key="true"/> + <genOperations xsi:type="genmodel:GenOperation" ecoreOperation="filters.ecore#//Filter/matches"> + <genParameters xsi:type="genmodel:GenParameter" ecoreParameter="filters.ecore#//Filter/matches/input"/> + </genOperations> + </genClasses> <genClasses xsi:type="genmodel:GenClass" ecoreClass="filters.ecore#//CompoundFilter"> <genFeatures xsi:type="genmodel:GenFeature" createChild="false" propertySortChoices="true" ecoreFeature="ecore:EReference filters.ecore#//CompoundFilter/filter"/> @@ -58,13 +70,6 @@ <genParameters xsi:type="genmodel:GenParameter" ecoreParameter="filters.ecore#//CompoundFilter/acyclic/context"/> </genOperations> </genClasses> - <genClasses xsi:type="genmodel:GenClass" image="false" ecoreClass="filters.ecore#//Filter"> - <genFeatures xsi:type="genmodel:GenFeature" createChild="false" ecoreFeature="ecore:EAttribute filters.ecore#//Filter/name" - key="true"/> - <genOperations xsi:type="genmodel:GenOperation" ecoreOperation="filters.ecore#//Filter/matches"> - <genParameters xsi:type="genmodel:GenParameter" ecoreParameter="filters.ecore#//Filter/matches/input"/> - </genOperations> - </genClasses> <genClasses xsi:type="genmodel:GenClass" ecoreClass="filters.ecore#//Equals"> <genFeatures xsi:type="genmodel:GenFeature" createChild="false" ecoreFeature="ecore:EAttribute filters.ecore#//Equals/object"/> </genClasses> diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/model/filters.notation b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/model/filters.notation index f16e6a6717d..24447cd4625 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/model/filters.notation +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/model/filters.notation @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8"?> -<xmi:XMI xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:css="http://www.eclipse.org/papyrus/infra/gmfdiag/css" xmlns:notation="http://www.eclipse.org/gmf/runtime/1.0.2/notation" xmlns:style="http://www.eclipse.org/papyrus/infra/gmfdiag/style" xmlns:uml="http://www.eclipse.org/uml2/5.0.0/UML"> +<xmi:XMI xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:css="http://www.eclipse.org/papyrus/infra/gmfdiag/css" xmlns:notation="http://www.eclipse.org/gmf/runtime/1.0.3/notation" xmlns:style="http://www.eclipse.org/papyrus/infra/gmfdiag/style" xmlns:uml="http://www.eclipse.org/uml2/5.0.0/UML"> <notation:Diagram xmi:id="_u1eJYG86EeSumdlFUM6GVw" type="PapyrusUMLClassDiagram" name="classes" measurementUnit="Pixel"> <children xmi:type="notation:Shape" xmi:id="_lJJGoG89EeSumdlFUM6GVw" type="PrimitiveType_Shape"> <children xmi:type="notation:DecorationNode" xmi:id="_lJJtsG89EeSumdlFUM6GVw" type="PrimitiveType_NameLabel"/> @@ -151,14 +151,6 @@ <element xmi:type="uml:Constraint" href="filters.uml#_owJUgHDoEeSd2uG9uLSAYg"/> <layoutConstraint xmi:type="notation:Bounds" xmi:id="_owboYHDoEeSd2uG9uLSAYg" x="275" y="431"/> </children> - <children xmi:type="notation:Shape" xmi:id="_kpDmUIytEeeCnq5i7PgOZA" type="StereotypeComment"> - <styles xmi:type="notation:TitleStyle" xmi:id="_kpDmUYytEeeCnq5i7PgOZA"/> - <styles xmi:type="notation:EObjectValueStyle" xmi:id="_kpDmU4ytEeeCnq5i7PgOZA" name="BASE_ELEMENT"> - <eObjectValue xmi:type="uml:PrimitiveType" href="filters.uml#_lJH4gG89EeSumdlFUM6GVw"/> - </styles> - <element xsi:nil="true"/> - <layoutConstraint xmi:type="notation:Bounds" xmi:id="_kpDmUoytEeeCnq5i7PgOZA" x="200" y="100"/> - </children> <children xmi:type="notation:Shape" xmi:id="_xqqJgIyvEeesNNBCp0L8sw" type="Class_Shape"> <children xmi:type="notation:DecorationNode" xmi:id="_xqrXoIyvEeesNNBCp0L8sw" type="Class_NameLabel"/> <children xmi:type="notation:DecorationNode" xmi:id="_xqrXoYyvEeesNNBCp0L8sw" type="Class_FloatingNameLabel"> @@ -185,7 +177,46 @@ <element xmi:type="uml:Class" href="filters.uml#_xqfKYIyvEeesNNBCp0L8sw"/> <layoutConstraint xmi:type="notation:Bounds" xmi:id="_xqqJgYyvEeesNNBCp0L8sw" x="640" y="46"/> </children> - <styles xmi:type="notation:StringValueStyle" xmi:id="_u1eJYW86EeSumdlFUM6GVw" name="diagram_compatibility_version" stringValue="1.3.0"/> + <children xmi:type="notation:Shape" xmi:id="_2bMQgIBCEeu6OKBomvawig" type="Class_Shape"> + <children xmi:type="notation:DecorationNode" xmi:id="_2bOFsIBCEeu6OKBomvawig" type="Class_NameLabel"/> + <children xmi:type="notation:DecorationNode" xmi:id="_2bOFsYBCEeu6OKBomvawig" type="Class_FloatingNameLabel"> + <layoutConstraint xmi:type="notation:Location" xmi:id="_2bOFsoBCEeu6OKBomvawig" y="15"/> + </children> + <children xmi:type="notation:BasicCompartment" xmi:id="_2bOFs4BCEeu6OKBomvawig" type="Class_AttributeCompartment"> + <styles xmi:type="notation:TitleStyle" xmi:id="_2bOFtIBCEeu6OKBomvawig"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_2bOFtYBCEeu6OKBomvawig"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_2bOFtoBCEeu6OKBomvawig"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_2bOFt4BCEeu6OKBomvawig"/> + </children> + <children xmi:type="notation:BasicCompartment" xmi:id="_2bOswIBCEeu6OKBomvawig" type="Class_OperationCompartment"> + <styles xmi:type="notation:TitleStyle" xmi:id="_2bOswYBCEeu6OKBomvawig"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_2bOswoBCEeu6OKBomvawig"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_2bOsw4BCEeu6OKBomvawig"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_2bOsxIBCEeu6OKBomvawig"/> + </children> + <children xmi:type="notation:BasicCompartment" xmi:id="_2bOsxYBCEeu6OKBomvawig" type="Class_NestedClassifierCompartment"> + <styles xmi:type="notation:TitleStyle" xmi:id="_2bOsxoBCEeu6OKBomvawig"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_2bOsx4BCEeu6OKBomvawig"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_2bOsyIBCEeu6OKBomvawig"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_2bOsyYBCEeu6OKBomvawig"/> + </children> + <element xmi:type="uml:Class" href="filters.uml#_2bBRYIBCEeu6OKBomvawig"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_2bMQgYBCEeu6OKBomvawig" x="560" y="240"/> + </children> + <children xmi:type="notation:Shape" xmi:id="_cCF7wJkuEeuRY-uNftq7KA" type="StereotypeComment"> + <styles xmi:type="notation:TitleStyle" xmi:id="_cCF7wZkuEeuRY-uNftq7KA"/> + <styles xmi:type="notation:EObjectValueStyle" xmi:id="_cCF7w5kuEeuRY-uNftq7KA" name="BASE_ELEMENT"> + <eObjectValue xmi:type="uml:PrimitiveType" href="filters.uml#_lJH4gG89EeSumdlFUM6GVw"/> + </styles> + <element xsi:nil="true"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_cCF7wpkuEeuRY-uNftq7KA" x="1040" y="40"/> + </children> + <children xmi:type="notation:Shape" xmi:id="_445vAJkuEeuRY-uNftq7KA" type="Comment_Shape"> + <children xmi:type="notation:DecorationNode" xmi:id="_446WEJkuEeuRY-uNftq7KA" type="Comment_BodyLabel"/> + <element xmi:type="uml:Comment" href="filters.uml#_441dkJkuEeuRY-uNftq7KA"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_445vAZkuEeuRY-uNftq7KA" x="676" y="224"/> + </children> + <styles xmi:type="notation:StringValueStyle" xmi:id="_u1eJYW86EeSumdlFUM6GVw" name="diagram_compatibility_version" stringValue="1.4.0"/> <styles xmi:type="notation:DiagramStyle" xmi:id="_u1eJYm86EeSumdlFUM6GVw"/> <styles xmi:type="style:PapyrusDiagramStyle" xmi:id="_ko-t0IytEeeCnq5i7PgOZA" diagramKindId="org.eclipse.papyrus.uml.diagram.class"> <owner xmi:type="uml:Model" href="filters.uml#_u1APUG86EeSumdlFUM6GVw"/> @@ -193,53 +224,65 @@ <element xmi:type="uml:Model" href="filters.uml#_u1APUG86EeSumdlFUM6GVw"/> <edges xmi:type="notation:Connector" xmi:id="_aNwhsG8-EeSumdlFUM6GVw" type="Association_Edge" source="_JBY8UG8-EeSumdlFUM6GVw" target="_fvId4HBiEeSbg_BqWNBy6A" routing="Rectilinear"> <children xmi:type="notation:DecorationNode" xmi:id="_aNxIwG8-EeSumdlFUM6GVw" type="Association_StereotypeLabel"> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_TrXmAIBDEeu6OKBomvawig" name="IS_UPDATED_POSITION" booleanValue="true"/> <layoutConstraint xmi:type="notation:Location" xmi:id="_aNxIwW8-EeSumdlFUM6GVw" y="-20"/> </children> <children xmi:type="notation:DecorationNode" xmi:id="_aNxIwm8-EeSumdlFUM6GVw" type="Association_NameLabel"> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_TroEsIBDEeu6OKBomvawig" name="IS_UPDATED_POSITION" booleanValue="true"/> <layoutConstraint xmi:type="notation:Location" xmi:id="_aNxIw28-EeSumdlFUM6GVw" y="20"/> </children> <children xmi:type="notation:DecorationNode" xmi:id="_aNxv0G8-EeSumdlFUM6GVw" type="Association_TargetRoleLabel"> - <layoutConstraint xmi:type="notation:Location" xmi:id="_aNxv0W8-EeSumdlFUM6GVw" x="-1" y="-49"/> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_Tr5KcIBDEeu6OKBomvawig" name="IS_UPDATED_POSITION" booleanValue="true"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_aNxv0W8-EeSumdlFUM6GVw" x="40" y="-49"/> </children> <children xmi:type="notation:DecorationNode" xmi:id="_aNxv0m8-EeSumdlFUM6GVw" type="Association_SourceRoleLabel"> - <layoutConstraint xmi:type="notation:Location" xmi:id="_aNxv028-EeSumdlFUM6GVw" y="20"/> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_TsJpIIBDEeu6OKBomvawig" name="IS_UPDATED_POSITION" booleanValue="true"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_aNxv028-EeSumdlFUM6GVw" x="-66" y="-16"/> </children> <children xmi:type="notation:DecorationNode" xmi:id="_aNxv1G8-EeSumdlFUM6GVw" type="Association_SourceMultiplicityLabel"> - <layoutConstraint xmi:type="notation:Location" xmi:id="_aNxv1W8-EeSumdlFUM6GVw" x="13" y="-17"/> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_TsZgwIBDEeu6OKBomvawig" name="IS_UPDATED_POSITION" booleanValue="true"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_aNxv1W8-EeSumdlFUM6GVw" x="54" y="-17"/> </children> <children xmi:type="notation:DecorationNode" xmi:id="_aNyW4G8-EeSumdlFUM6GVw" type="Association_TargetMultiplicityLabel"> - <layoutConstraint xmi:type="notation:Location" xmi:id="_aNyW4W8-EeSumdlFUM6GVw" y="-20"/> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_Tsp_cIBDEeu6OKBomvawig" name="IS_UPDATED_POSITION" booleanValue="true"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_aNyW4W8-EeSumdlFUM6GVw" x="-31" y="12"/> </children> <styles xmi:type="notation:FontStyle" xmi:id="_aNwhsW8-EeSumdlFUM6GVw"/> <element xmi:type="uml:Association" href="filters.uml#_aNqbEG8-EeSumdlFUM6GVw"/> - <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_aNwhsm8-EeSumdlFUM6GVw" points="[-10, 0, -74, 178]$[-10, -174, -74, 4]$[64, -174, 0, 4]"/> - <sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="_aO04sG8-EeSumdlFUM6GVw" id="(0.08227848101265822,0.0)"/> - <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_vJps0G8-EeSumdlFUM6GVw" id="(0.0,0.18421052631578946)"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_aNwhsm8-EeSumdlFUM6GVw" points="[180, 244, -643984, -643984]$[180, 60, -643984, -643984]$[252, 60, -643984, -643984]"/> + <sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="_aO04sG8-EeSumdlFUM6GVw" id="(0.10828025477707007,0.0)"/> + <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_vJps0G8-EeSumdlFUM6GVw" id="(0.0,0.12280701754385964)"/> </edges> <edges xmi:type="notation:Connector" xmi:id="_bUeeAHBCEeSbg_BqWNBy6A" type="Association_Edge" source="_JBY8UG8-EeSumdlFUM6GVw" target="_fvId4HBiEeSbg_BqWNBy6A" routing="Rectilinear"> <children xmi:type="notation:DecorationNode" xmi:id="_bUgTMHBCEeSbg_BqWNBy6A" type="Association_StereotypeLabel"> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_VQGvMIBDEeu6OKBomvawig" name="IS_UPDATED_POSITION" booleanValue="true"/> <layoutConstraint xmi:type="notation:Location" xmi:id="_bUgTMXBCEeSbg_BqWNBy6A" y="-20"/> </children> <children xmi:type="notation:DecorationNode" xmi:id="_bUg6QHBCEeSbg_BqWNBy6A" type="Association_NameLabel"> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_VQX08IBDEeu6OKBomvawig" name="IS_UPDATED_POSITION" booleanValue="true"/> <layoutConstraint xmi:type="notation:Location" xmi:id="_bUg6QXBCEeSbg_BqWNBy6A" y="20"/> </children> <children xmi:type="notation:DecorationNode" xmi:id="_bUg6QnBCEeSbg_BqWNBy6A" type="Association_TargetRoleLabel"> - <layoutConstraint xmi:type="notation:Location" xmi:id="_bUg6Q3BCEeSbg_BqWNBy6A" x="13" y="31"/> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_VQoToIBDEeu6OKBomvawig" name="IS_UPDATED_POSITION" booleanValue="true"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_bUg6Q3BCEeSbg_BqWNBy6A" x="41" y="31"/> </children> <children xmi:type="notation:DecorationNode" xmi:id="_bUhhUHBCEeSbg_BqWNBy6A" type="Association_SourceRoleLabel"> - <layoutConstraint xmi:type="notation:Location" xmi:id="_bUhhUXBCEeSbg_BqWNBy6A" y="20"/> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_VQ6AcIBDEeu6OKBomvawig" name="IS_UPDATED_POSITION" booleanValue="true"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_bUhhUXBCEeSbg_BqWNBy6A" x="-33" y="-14"/> </children> <children xmi:type="notation:DecorationNode" xmi:id="_bUhhUnBCEeSbg_BqWNBy6A" type="Association_SourceMultiplicityLabel"> - <layoutConstraint xmi:type="notation:Location" xmi:id="_bUhhU3BCEeSbg_BqWNBy6A" x="-2" y="14"/> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_VRLGMIBDEeu6OKBomvawig" name="IS_UPDATED_POSITION" booleanValue="true"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_bUhhU3BCEeSbg_BqWNBy6A" x="26" y="14"/> </children> <children xmi:type="notation:DecorationNode" xmi:id="_bUhhVHBCEeSbg_BqWNBy6A" type="Association_TargetMultiplicityLabel"> - <layoutConstraint xmi:type="notation:Location" xmi:id="_bUhhVXBCEeSbg_BqWNBy6A" y="-20"/> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_VRczAIBDEeu6OKBomvawig" name="IS_UPDATED_POSITION" booleanValue="true"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_bUhhVXBCEeSbg_BqWNBy6A" x="-15" y="23"/> </children> <styles xmi:type="notation:FontStyle" xmi:id="_bUeeAXBCEeSbg_BqWNBy6A"/> <element xmi:type="uml:Association" href="filters.uml#_bTEv0HBCEeSbg_BqWNBy6A"/> - <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_bUeeAnBCEeSbg_BqWNBy6A" points="[-1, 0, -57, 113]$[-1, -111, -57, 2]$[56, -111, 0, 2]"/> - <sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="_bUynEHBCEeSbg_BqWNBy6A" id="(0.2088607594936709,0.0)"/> - <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_bUzOIHBCEeSbg_BqWNBy6A" id="(0.0,0.7456140350877193)"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_bUeeAnBCEeSbg_BqWNBy6A" points="[200, 244, -643984, -643984]$[200, 120, -643984, -643984]$[252, 120, -643984, -643984]"/> + <sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="_bUynEHBCEeSbg_BqWNBy6A" id="(0.2356687898089172,0.0)"/> + <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_bUzOIHBCEeSbg_BqWNBy6A" id="(0.0,0.6491228070175439)"/> </edges> <edges xmi:type="notation:Connector" xmi:id="_ssiHQHBIEeSbg_BqWNBy6A" type="Generalization_Edge" source="_JBY8UG8-EeSumdlFUM6GVw" target="_fvId4HBiEeSbg_BqWNBy6A"> <children xmi:type="notation:DecorationNode" xmi:id="_ssiHQ3BIEeSbg_BqWNBy6A" type="Generalization_StereotypeLabel"> @@ -271,16 +314,6 @@ <sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="_pDUvMHDoEeSd2uG9uLSAYg" id="(0.0,0.0)"/> <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_pdKykHDoEeSd2uG9uLSAYg" id="(0.5759493670886076,1.0)"/> </edges> - <edges xmi:type="notation:Connector" xmi:id="_kpENYIytEeeCnq5i7PgOZA" type="StereotypeCommentLink" source="_lJJGoG89EeSumdlFUM6GVw" target="_kpDmUIytEeeCnq5i7PgOZA"> - <styles xmi:type="notation:FontStyle" xmi:id="_kpE0cIytEeeCnq5i7PgOZA"/> - <styles xmi:type="notation:EObjectValueStyle" xmi:id="_kpE0dIytEeeCnq5i7PgOZA" name="BASE_ELEMENT"> - <eObjectValue xmi:type="uml:PrimitiveType" href="filters.uml#_lJH4gG89EeSumdlFUM6GVw"/> - </styles> - <element xsi:nil="true"/> - <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_kpE0cYytEeeCnq5i7PgOZA" points="[0, 0, 0, 0]$[0, 0, 0, 0]"/> - <sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="_kpE0coytEeeCnq5i7PgOZA"/> - <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_kpE0c4ytEeeCnq5i7PgOZA"/> - </edges> <edges xmi:type="notation:Connector" xmi:id="_zL1oYIyvEeesNNBCp0L8sw" type="Association_Edge" source="_xqqJgIyvEeesNNBCp0L8sw" target="_fvId4HBiEeSbg_BqWNBy6A"> <children xmi:type="notation:DecorationNode" xmi:id="_zL2PcIyvEeesNNBCp0L8sw" type="Association_StereotypeLabel"> <layoutConstraint xmi:type="notation:Location" xmi:id="_zL2PcYyvEeesNNBCp0L8sw" y="-20"/> @@ -289,7 +322,7 @@ <layoutConstraint xmi:type="notation:Location" xmi:id="_zL2Pc4yvEeesNNBCp0L8sw" y="20"/> </children> <children xmi:type="notation:DecorationNode" xmi:id="_zL2PdIyvEeesNNBCp0L8sw" type="Association_TargetRoleLabel"> - <layoutConstraint xmi:type="notation:Location" xmi:id="_zL2PdYyvEeesNNBCp0L8sw" y="-20"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_zL2PdYyvEeesNNBCp0L8sw" x="27" y="-14"/> </children> <children xmi:type="notation:DecorationNode" xmi:id="_zL2PdoyvEeesNNBCp0L8sw" type="Association_SourceRoleLabel"> <layoutConstraint xmi:type="notation:Location" xmi:id="_zL2Pd4yvEeesNNBCp0L8sw" y="20"/> @@ -303,8 +336,91 @@ <styles xmi:type="notation:FontStyle" xmi:id="_zL1oYYyvEeesNNBCp0L8sw"/> <element xmi:type="uml:Association" href="filters.uml#_zLOkYIyvEeesNNBCp0L8sw"/> <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_zL1oYoyvEeesNNBCp0L8sw"/> - <sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="_zMnEcIyvEeesNNBCp0L8sw" id="(0.0,0.54)"/> - <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_zMnEcYyvEeesNNBCp0L8sw" id="(1.0,0.46153846153846156)"/> + <sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="_zMnEcIyvEeesNNBCp0L8sw" id="(0.0,0.1)"/> + <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_zMnEcYyvEeesNNBCp0L8sw" id="(1.0,0.10526315789473684)"/> + </edges> + <edges xmi:type="notation:Connector" xmi:id="_AQxOgIBDEeu6OKBomvawig" type="Association_Edge" source="_2bMQgIBCEeu6OKBomvawig" target="_fvId4HBiEeSbg_BqWNBy6A"> + <children xmi:type="notation:DecorationNode" xmi:id="_AQx1kIBDEeu6OKBomvawig" type="Association_StereotypeLabel"> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_KXUnwIBDEeu6OKBomvawig" name="IS_UPDATED_POSITION" booleanValue="true"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_AQx1kYBDEeu6OKBomvawig" y="-20"/> + </children> + <children xmi:type="notation:DecorationNode" xmi:id="_AQx1koBDEeu6OKBomvawig" type="Association_NameLabel"> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_KXvegIBDEeu6OKBomvawig" name="IS_UPDATED_POSITION" booleanValue="true"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_AQx1k4BDEeu6OKBomvawig" y="20"/> + </children> + <children xmi:type="notation:DecorationNode" xmi:id="_AQx1lIBDEeu6OKBomvawig" type="Association_TargetRoleLabel"> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_KYFcwIBDEeu6OKBomvawig" name="IS_UPDATED_POSITION" booleanValue="true"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_AQx1lYBDEeu6OKBomvawig" x="36" y="-30"/> + </children> + <children xmi:type="notation:DecorationNode" xmi:id="_AQx1loBDEeu6OKBomvawig" type="Association_SourceRoleLabel"> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_KYdQMIBDEeu6OKBomvawig" name="IS_UPDATED_POSITION" booleanValue="true"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_AQx1l4BDEeu6OKBomvawig" x="-41" y="-13"/> + </children> + <children xmi:type="notation:DecorationNode" xmi:id="_AQx1mIBDEeu6OKBomvawig" type="Association_SourceMultiplicityLabel"> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_KYynYIBDEeu6OKBomvawig" name="IS_UPDATED_POSITION" booleanValue="true"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_AQx1mYBDEeu6OKBomvawig" x="15" y="-16"/> + </children> + <children xmi:type="notation:DecorationNode" xmi:id="_AQx1moBDEeu6OKBomvawig" type="Association_TargetMultiplicityLabel"> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_KZJMsIBDEeu6OKBomvawig" name="IS_UPDATED_POSITION" booleanValue="true"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_AQx1m4BDEeu6OKBomvawig" x="-71" y="-14"/> + </children> + <styles xmi:type="notation:FontStyle" xmi:id="_AQxOgYBDEeu6OKBomvawig"/> + <element xmi:type="uml:Association" href="filters.uml#_AQQ4MIBDEeu6OKBomvawig"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_AQxOgoBDEeu6OKBomvawig" points="[580, 240, -643984, -643984]$[580, 140, -643984, -643984]$[451, 140, -643984, -643984]"/> + <sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="_ARlt4IBDEeu6OKBomvawig" id="(0.2,0.0)"/> + <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_ARlt4YBDEeu6OKBomvawig" id="(1.0,0.8245614035087719)"/> + </edges> + <edges xmi:type="notation:Connector" xmi:id="_JiTEQIBDEeu6OKBomvawig" type="Generalization_Edge" source="_2bMQgIBCEeu6OKBomvawig" target="_fvId4HBiEeSbg_BqWNBy6A"> + <children xmi:type="notation:DecorationNode" xmi:id="_JiTEQ4BDEeu6OKBomvawig" type="Generalization_StereotypeLabel"> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_P1HtMIBDEeu6OKBomvawig" name="IS_UPDATED_POSITION" booleanValue="true"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_JiTERIBDEeu6OKBomvawig" x="-1" y="38"/> + </children> + <styles xmi:type="notation:FontStyle" xmi:id="_JiTEQYBDEeu6OKBomvawig"/> + <element xmi:type="uml:Generalization" href="filters.uml#_Jh9GAIBDEeu6OKBomvawig"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_JiTEQoBDEeu6OKBomvawig" points="[640, 260, -643984, -643984]$[451, 120, -643984, -643984]"/> + <sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="_JjBdAIBDEeu6OKBomvawig" id="(0.0,0.2)"/> + <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_JjBdAYBDEeu6OKBomvawig" id="(0.8442211055276382,1.0)"/> + </edges> + <edges xmi:type="notation:Connector" xmi:id="_cCF7xJkuEeuRY-uNftq7KA" type="StereotypeCommentLink" source="_lJJGoG89EeSumdlFUM6GVw" target="_cCF7wJkuEeuRY-uNftq7KA"> + <styles xmi:type="notation:FontStyle" xmi:id="_cCF7xZkuEeuRY-uNftq7KA"/> + <styles xmi:type="notation:EObjectValueStyle" xmi:id="_cCF7yZkuEeuRY-uNftq7KA" name="BASE_ELEMENT"> + <eObjectValue xmi:type="uml:PrimitiveType" href="filters.uml#_lJH4gG89EeSumdlFUM6GVw"/> + </styles> + <element xsi:nil="true"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_cCF7xpkuEeuRY-uNftq7KA" points="[0, 0, 0, 0]$[0, 0, 0, 0]"/> + <sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="_cCF7x5kuEeuRY-uNftq7KA"/> + <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_cCF7yJkuEeuRY-uNftq7KA"/> + </edges> + <edges xmi:type="notation:Connector" xmi:id="_iJOSEJkuEeuRY-uNftq7KA" type="Association_Edge" source="_2bMQgIBCEeu6OKBomvawig" target="_fvId4HBiEeSbg_BqWNBy6A"> + <children xmi:type="notation:DecorationNode" xmi:id="_iJO5IJkuEeuRY-uNftq7KA" type="Association_StereotypeLabel"> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_iwKWQJkuEeuRY-uNftq7KA" name="IS_UPDATED_POSITION" booleanValue="true"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_iJO5IZkuEeuRY-uNftq7KA" y="-20"/> + </children> + <children xmi:type="notation:DecorationNode" xmi:id="_iJO5IpkuEeuRY-uNftq7KA" type="Association_NameLabel"> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_iwl0EJkuEeuRY-uNftq7KA" name="IS_UPDATED_POSITION" booleanValue="true"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_iJO5I5kuEeuRY-uNftq7KA" y="20"/> + </children> + <children xmi:type="notation:DecorationNode" xmi:id="_iJO5JJkuEeuRY-uNftq7KA" type="Association_TargetRoleLabel"> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_iw-1oJkuEeuRY-uNftq7KA" name="IS_UPDATED_POSITION" booleanValue="true"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_iJO5JZkuEeuRY-uNftq7KA" x="37" y="52"/> + </children> + <children xmi:type="notation:DecorationNode" xmi:id="_iJO5JpkuEeuRY-uNftq7KA" type="Association_SourceRoleLabel"> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_ixYeQJkuEeuRY-uNftq7KA" name="IS_UPDATED_POSITION" booleanValue="true"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_iJO5J5kuEeuRY-uNftq7KA" x="-38" y="15"/> + </children> + <children xmi:type="notation:DecorationNode" xmi:id="_iJO5KJkuEeuRY-uNftq7KA" type="Association_SourceMultiplicityLabel"> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_ixw4wJkuEeuRY-uNftq7KA" name="IS_UPDATED_POSITION" booleanValue="true"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_iJO5KZkuEeuRY-uNftq7KA" x="16" y="20"/> + </children> + <children xmi:type="notation:DecorationNode" xmi:id="_iJO5KpkuEeuRY-uNftq7KA" type="Association_TargetMultiplicityLabel"> + <styles xmi:type="notation:BooleanValueStyle" xmi:id="_iyLIcJkuEeuRY-uNftq7KA" name="IS_UPDATED_POSITION" booleanValue="true"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_iJO5K5kuEeuRY-uNftq7KA" x="-87" y="13"/> + </children> + <styles xmi:type="notation:FontStyle" xmi:id="_iJOSEZkuEeuRY-uNftq7KA"/> + <element xmi:type="uml:Association" href="filters.uml#_iIwYAJkuEeuRY-uNftq7KA"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_iJOSEpkuEeuRY-uNftq7KA" points="[621, 240, -643984, -643984]$[621, 115, -643984, -643984]$[451, 115, -643984, -643984]"/> + <sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="_iKO-sJkuEeuRY-uNftq7KA" id="(0.63,0.0)"/> + <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_iKPlwJkuEeuRY-uNftq7KA" id="(1.0,0.6052631578947368)"/> </edges> </notation:Diagram> <css:ModelStyleSheets xmi:id="_Xbyl0G89EeSumdlFUM6GVw"/> diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/model/filters.uml b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/model/filters.uml index 986960b2c35..892c9f6ac27 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/model/filters.uml +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/model/filters.uml @@ -1,6 +1,13 @@ <?xml version="1.0" encoding="UTF-8"?> <xmi:XMI xmi:version="20131001" xmlns:xmi="http://www.omg.org/spec/XMI/20131001" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:Ecore="http://www.eclipse.org/uml2/schemas/Ecore/5" xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" xmlns:uml="http://www.eclipse.org/uml2/5.0.0/UML" xsi:schemaLocation="http://www.eclipse.org/uml2/schemas/Ecore/5 pathmap://UML_PROFILES/Ecore.profile.uml#_z1OFcHjqEdy8S4Cr8Rc_NA"> <uml:Model xmi:id="_u1APUG86EeSumdlFUM6GVw" name="filters" URI="http://www.eclipse.org/Papyrus/2014/common/filters" viewpoint=""> + <ownedComment xmi:type="uml:Comment" xmi:id="_441dkJkuEeuRY-uNftq7KA" annotatedElement="_iIy0QJkuEeuRY-uNftq7KA"> + <body>Owning the indirect reference +lets a dependent model that uses +filters access all available child +creation extenders, when it cannot +access those extenders, itself.</body> + </ownedComment> <packageImport xmi:type="uml:PackageImport" xmi:id="_u1APUW86EeSumdlFUM6GVw"> <importedPackage xmi:type="uml:Model" href="pathmap://UML_LIBRARIES/UMLPrimitiveTypes.library.uml#_0"/> </packageImport> @@ -72,6 +79,35 @@ </eAnnotations> <ownedEnd xmi:type="uml:Property" xmi:id="_zLUD8IyvEeesNNBCp0L8sw" name="filteredelement" type="_xqfKYIyvEeesNNBCp0L8sw" association="_zLOkYIyvEeesNNBCp0L8sw"/> </packagedElement> + <packagedElement xmi:type="uml:Class" xmi:id="_2bBRYIBCEeu6OKBomvawig" name="FilterReference"> + <ownedComment xmi:type="uml:Comment" xmi:id="__UrZsIBCEeu6OKBomvawig" annotatedElement="_2bBRYIBCEeu6OKBomvawig"> + <body>A filter that redirects to a referenced filter. Useful to reuse filters by reference in any +context where otherwise the filtered element doesn't support shared filters.</body> + </ownedComment> + <generalization xmi:type="uml:Generalization" xmi:id="_Jh9GAIBDEeu6OKBomvawig" general="_ftlkkHBIEeSbg_BqWNBy6A"/> + <ownedAttribute xmi:type="uml:Property" xmi:id="_AQT7gIBDEeu6OKBomvawig" name="filter" type="_ftlkkHBIEeSbg_BqWNBy6A" association="_AQQ4MIBDEeu6OKBomvawig"/> + <ownedAttribute xmi:type="uml:Property" xmi:id="_iIy0QJkuEeuRY-uNftq7KA" name="ownedFilter" type="_ftlkkHBIEeSbg_BqWNBy6A" aggregation="composite" subsettedProperty="_AQT7gIBDEeu6OKBomvawig" association="_iIwYAJkuEeuRY-uNftq7KA"> + <lowerValue xmi:type="uml:LiteralInteger" xmi:id="_iIzbUJkuEeuRY-uNftq7KA"/> + <upperValue xmi:type="uml:LiteralUnlimitedNatural" xmi:id="_iIzbUZkuEeuRY-uNftq7KA" value="1"/> + </ownedAttribute> + </packagedElement> + <packagedElement xmi:type="uml:Association" xmi:id="_AQQ4MIBDEeu6OKBomvawig" memberEnd="_AQT7gIBDEeu6OKBomvawig _AQb3UIBDEeu6OKBomvawig"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_AQTUcIBDEeu6OKBomvawig" source="org.eclipse.papyrus"> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_AQTUcYBDEeu6OKBomvawig" key="nature" value="UML_Nature"/> + </eAnnotations> + <ownedEnd xmi:type="uml:Property" xmi:id="_AQb3UIBDEeu6OKBomvawig" name="reference" type="_2bBRYIBCEeu6OKBomvawig" association="_AQQ4MIBDEeu6OKBomvawig"> + <lowerValue xmi:type="uml:LiteralInteger" xmi:id="_EGMA4IBDEeu6OKBomvawig"/> + <upperValue xmi:type="uml:LiteralUnlimitedNatural" xmi:id="_EGOdIIBDEeu6OKBomvawig" value="*"/> + </ownedEnd> + </packagedElement> + <packagedElement xmi:type="uml:Association" xmi:id="_iIwYAJkuEeuRY-uNftq7KA" memberEnd="_iIy0QJkuEeuRY-uNftq7KA _iIzbUpkuEeuRY-uNftq7KA"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_iIyNMJkuEeuRY-uNftq7KA" source="org.eclipse.papyrus"> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_iIyNMZkuEeuRY-uNftq7KA" key="nature" value="UML_Nature"/> + </eAnnotations> + <ownedEnd xmi:type="uml:Property" xmi:id="_iIzbUpkuEeuRY-uNftq7KA" name="owningReference" type="_2bBRYIBCEeu6OKBomvawig" subsettedProperty="_AQb3UIBDEeu6OKBomvawig" association="_iIwYAJkuEeuRY-uNftq7KA"> + <lowerValue xmi:type="uml:LiteralInteger" xmi:id="_vw8sAJkuEeuRY-uNftq7KA"/> + </ownedEnd> + </packagedElement> <profileApplication xmi:type="uml:ProfileApplication" xmi:id="_b_yVcG89EeSumdlFUM6GVw"> <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_cAQPgG89EeSumdlFUM6GVw" source="http://www.eclipse.org/uml2/2.0.0/UML"> <references xmi:type="ecore:EPackage" href="pathmap://UML_PROFILES/Ecore.profile.uml#_z1OFcHjqEdy8S4Cr8Rc_NA"/> diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/pom.xml b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/pom.xml index b1dd49b5f54..403979a01da 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/pom.xml +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/pom.xml @@ -1,5 +1,6 @@ <?xml version="1.0" encoding="UTF-8"?> -<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" +<project xmlns="http://maven.apache.org/POM/4.0.0" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> <parent> @@ -8,6 +9,6 @@ <version>0.0.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.papyrus.infra.filters</artifactId> - <version>1.3.0-SNAPSHOT</version> + <version>2.0.0-SNAPSHOT</version> <packaging>eclipse-plugin</packaging> -</project> +</project>
\ No newline at end of file diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/CompoundFilter.java b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/CompoundFilter.java index 61266aa58cc..f649933156f 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/CompoundFilter.java +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/CompoundFilter.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2014 Christian W. Damus and others. + * Copyright (c) 2014, 2021 Christian W. Damus, CEA LIST, and others. * * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License 2.0 @@ -60,7 +60,7 @@ public interface CompoundFilter extends Filter { * <!-- end-user-doc --> * * @param name - * The '<em><b>Name</b></em>' of the {@link org.eclipse.papyrus.infra.filters.Filter} to retrieve, or <code>null</code>. + * The '<em><b>Name</b></em>' of the {@link org.eclipse.papyrus.infra.filters.Filter} to retrieve, or <code>null</code>. * @return The first {@link org.eclipse.papyrus.infra.filters.Filter} with the specified '<em><b>Name</b></em>', or <code>null</code>. * @see #getFilters() * @generated @@ -73,11 +73,11 @@ public interface CompoundFilter extends Filter { * <!-- end-user-doc --> * * @param name - * The '<em><b>Name</b></em>' of the {@link org.eclipse.papyrus.infra.filters.Filter} to retrieve, or <code>null</code>. + * The '<em><b>Name</b></em>' of the {@link org.eclipse.papyrus.infra.filters.Filter} to retrieve, or <code>null</code>. * @param ignoreCase - * Whether to ignore case in {@link java.lang.String} comparisons. + * Whether to ignore case in {@link java.lang.String} comparisons. * @param eClass - * The Ecore class of the {@link org.eclipse.papyrus.infra.filters.Filter} to retrieve, or <code>null</code>. + * The Ecore class of the {@link org.eclipse.papyrus.infra.filters.Filter} to retrieve, or <code>null</code>. * @return The first {@link org.eclipse.papyrus.infra.filters.Filter} with the specified '<em><b>Name</b></em>', or <code>null</code>. * @see #getFilters() * @generated @@ -102,6 +102,7 @@ public interface CompoundFilter extends Filter { * @return the value of the '<em>Owned Filter</em>' containment reference list. * @see org.eclipse.papyrus.infra.filters.FiltersPackage#getCompoundFilter_OwnedFilter() * @model containment="true" ordered="false" + * annotation="subsets" * @generated */ EList<Filter> getOwnedFilters(); @@ -112,9 +113,9 @@ public interface CompoundFilter extends Filter { * <!-- end-user-doc --> * * @param name - * The '<em><b>Name</b></em>' for the new {@link org.eclipse.papyrus.infra.filters.Filter}, or <code>null</code>. + * The '<em><b>Name</b></em>' for the new {@link org.eclipse.papyrus.infra.filters.Filter}, or <code>null</code>. * @param eClass - * The Ecore class of the {@link org.eclipse.papyrus.infra.filters.Filter} to create. + * The Ecore class of the {@link org.eclipse.papyrus.infra.filters.Filter} to create. * @return The new {@link org.eclipse.papyrus.infra.filters.Filter}. * @see #getOwnedFilters() * @generated @@ -127,7 +128,7 @@ public interface CompoundFilter extends Filter { * <!-- end-user-doc --> * * @param name - * The '<em><b>Name</b></em>' of the {@link org.eclipse.papyrus.infra.filters.Filter} to retrieve, or <code>null</code>. + * The '<em><b>Name</b></em>' of the {@link org.eclipse.papyrus.infra.filters.Filter} to retrieve, or <code>null</code>. * @return The first {@link org.eclipse.papyrus.infra.filters.Filter} with the specified '<em><b>Name</b></em>', or <code>null</code>. * @see #getOwnedFilters() * @generated @@ -140,13 +141,13 @@ public interface CompoundFilter extends Filter { * <!-- end-user-doc --> * * @param name - * The '<em><b>Name</b></em>' of the {@link org.eclipse.papyrus.infra.filters.Filter} to retrieve, or <code>null</code>. + * The '<em><b>Name</b></em>' of the {@link org.eclipse.papyrus.infra.filters.Filter} to retrieve, or <code>null</code>. * @param ignoreCase - * Whether to ignore case in {@link java.lang.String} comparisons. + * Whether to ignore case in {@link java.lang.String} comparisons. * @param eClass - * The Ecore class of the {@link org.eclipse.papyrus.infra.filters.Filter} to retrieve, or <code>null</code>. + * The Ecore class of the {@link org.eclipse.papyrus.infra.filters.Filter} to retrieve, or <code>null</code>. * @param createOnDemand - * Whether to create a {@link org.eclipse.papyrus.infra.filters.Filter} on demand if not found. + * Whether to create a {@link org.eclipse.papyrus.infra.filters.Filter} on demand if not found. * @return The first {@link org.eclipse.papyrus.infra.filters.Filter} with the specified '<em><b>Name</b></em>', or <code>null</code>. * @see #getOwnedFilters() * @generated @@ -177,7 +178,7 @@ public interface CompoundFilter extends Filter { * <!-- end-user-doc --> * * @param value - * the new value of the '<em>Operator</em>' attribute. + * the new value of the '<em>Operator</em>' attribute. * @see org.eclipse.papyrus.infra.filters.OperatorKind * @see #getOperator() * @generated @@ -191,10 +192,10 @@ public interface CompoundFilter extends Filter { * A filter may not directly or indirectly compose itself. * * @param diagnostics - * The chain of diagnostics to which problems are to be appended. + * The chain of diagnostics to which problems are to be appended. * @param context - * The cache of context-specific information. - * <!-- end-model-doc --> + * The cache of context-specific information. + * <!-- end-model-doc --> * @model * @generated */ diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/Equals.java b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/Equals.java index c2c2d2e8cfc..530eadb1457 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/Equals.java +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/Equals.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2014 Christian W. Damus and others. + * Copyright (c) 2014, 2021 Christian W. Damus, CEA LIST, and others. * * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License 2.0 @@ -53,7 +53,7 @@ public interface Equals extends Filter { * <!-- end-user-doc --> * * @param value - * the new value of the '<em>Object</em>' attribute. + * the new value of the '<em>Object</em>' attribute. * @see #getObject() * @generated */ diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/Filter.java b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/Filter.java index 817d73f6e12..6a015eb6648 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/Filter.java +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/Filter.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2014 Christian W. Damus and others. + * Copyright (c) 2014, 2021 Christian W. Damus, CEA LIST, and others. * * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License 2.0 @@ -54,7 +54,7 @@ public interface Filter extends EObject { * <!-- end-user-doc --> * * @param value - * the new value of the '<em>Name</em>' attribute. + * the new value of the '<em>Name</em>' attribute. * @see #getName() * @generated */ diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/FilterReference.java b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/FilterReference.java new file mode 100644 index 00000000000..83e7953e64c --- /dev/null +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/FilterReference.java @@ -0,0 +1,125 @@ +/** + * Copyright (c) 2021 Christian W. Damus, CEA LIST, and others. + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the Eclipse Public License 2.0 + * which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-2.0/ + * + * SPDX-License-Identifier: EPL-2.0 + * + * Contributors: + * Christian W. Damus - Initial API and implementation + */ +package org.eclipse.papyrus.infra.filters; + +import org.eclipse.emf.ecore.EClass; + + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Filter Reference</b></em>'. + * <!-- end-user-doc --> + * + * <!-- begin-model-doc --> + * A filter that redirects to a referenced filter. Useful to reuse filters by reference in any + * context where otherwise the filtered element doesn't support shared filters. + * <!-- end-model-doc --> + * + * <p> + * The following features are supported: + * </p> + * <ul> + * <li>{@link org.eclipse.papyrus.infra.filters.FilterReference#getFilter <em>Filter</em>}</li> + * <li>{@link org.eclipse.papyrus.infra.filters.FilterReference#getOwnedFilter <em>Owned Filter</em>}</li> + * </ul> + * + * @see org.eclipse.papyrus.infra.filters.FiltersPackage#getFilterReference() + * @model + * @generated + */ +public interface FilterReference extends Filter { + /** + * Returns the value of the '<em><b>Filter</b></em>' reference. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Filter</em>' reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * + * @return the value of the '<em>Filter</em>' reference. + * @see #setFilter(Filter) + * @see org.eclipse.papyrus.infra.filters.FiltersPackage#getFilterReference_Filter() + * @model required="true" ordered="false" + * @generated + */ + Filter getFilter(); + + /** + * Sets the value of the '{@link org.eclipse.papyrus.infra.filters.FilterReference#getFilter <em>Filter</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @param value + * the new value of the '<em>Filter</em>' reference. + * @see #getFilter() + * @generated + */ + void setFilter(Filter value); + + /** + * Returns the value of the '<em><b>Owned Filter</b></em>' containment reference. + * <p> + * This feature subsets the following features: + * </p> + * <ul> + * <li>'{@link org.eclipse.papyrus.infra.filters.FilterReference#getFilter() <em>Filter</em>}'</li> + * </ul> + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * <!-- begin-model-doc --> + * Owning the indirect reference + * lets a dependent model that uses + * filters access all available child + * creation extenders, when it cannot + * access those extenders, itself. + * <!-- end-model-doc --> + * + * @return the value of the '<em>Owned Filter</em>' containment reference. + * @see #setOwnedFilter(Filter) + * @see org.eclipse.papyrus.infra.filters.FiltersPackage#getFilterReference_OwnedFilter() + * @model containment="true" ordered="false" + * annotation="subsets" + * @generated + */ + Filter getOwnedFilter(); + + /** + * Sets the value of the '{@link org.eclipse.papyrus.infra.filters.FilterReference#getOwnedFilter <em>Owned Filter</em>}' containment reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @param value + * the new value of the '<em>Owned Filter</em>' containment reference. + * @see #getOwnedFilter() + * @generated + */ + void setOwnedFilter(Filter value); + + /** + * Creates a new {@link org.eclipse.papyrus.infra.filters.Filter}, with the specified '<em><b>Name</b></em>', and sets the '<em><b>Owned Filter</b></em>' containment reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @param name + * The '<em><b>Name</b></em>' for the new {@link org.eclipse.papyrus.infra.filters.Filter}, or <code>null</code>. + * @param eClass + * The Ecore class of the {@link org.eclipse.papyrus.infra.filters.Filter} to create. + * @return The new {@link org.eclipse.papyrus.infra.filters.Filter}. + * @see #getOwnedFilter() + * @generated + */ + Filter createOwnedFilter(String name, EClass eClass); + +} // FilterReference diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/FilteredElement.java b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/FilteredElement.java index 85b772be394..d84191fad74 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/FilteredElement.java +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/FilteredElement.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2014 Christian W. Damus and others. + * Copyright (c) 2014, 2021 Christian W. Damus, CEA LIST, and others. * * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License 2.0 @@ -31,7 +31,6 @@ import org.eclipse.emf.ecore.EObject; * @see org.eclipse.papyrus.infra.filters.FiltersPackage#getFilteredElement() * @model * @generated - * @since 1.3 */ public interface FilteredElement extends EObject { /** @@ -57,7 +56,7 @@ public interface FilteredElement extends EObject { * <!-- end-user-doc --> * * @param value - * the new value of the '<em>Filter</em>' containment reference. + * the new value of the '<em>Filter</em>' containment reference. * @see #getFilter() * @generated */ @@ -69,9 +68,9 @@ public interface FilteredElement extends EObject { * <!-- end-user-doc --> * * @param name - * The '<em><b>Name</b></em>' for the new {@link org.eclipse.papyrus.infra.filters.Filter}, or <code>null</code>. + * The '<em><b>Name</b></em>' for the new {@link org.eclipse.papyrus.infra.filters.Filter}, or <code>null</code>. * @param eClass - * The Ecore class of the {@link org.eclipse.papyrus.infra.filters.Filter} to create. + * The Ecore class of the {@link org.eclipse.papyrus.infra.filters.Filter} to create. * @return The new {@link org.eclipse.papyrus.infra.filters.Filter}. * @see #getFilter() * @generated diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/FiltersFactory.java b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/FiltersFactory.java index 1e5575fed47..61c4a534fe5 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/FiltersFactory.java +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/FiltersFactory.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2014 Christian W. Damus and others. + * Copyright (c) 2014, 2021 Christian W. Damus, CEA LIST, and others. * * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License 2.0 @@ -61,11 +61,20 @@ public interface FiltersFactory extends EFactory { * * @return a new object of class '<em>Filtered Element</em>'. * @generated - * @since 1.3 */ FilteredElement createFilteredElement(); /** + * Returns a new object of class '<em>Filter Reference</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @return a new object of class '<em>Filter Reference</em>'. + * @generated + */ + FilterReference createFilterReference(); + + /** * Returns the package supported by this factory. * <!-- begin-user-doc --> * <!-- end-user-doc --> diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/FiltersPackage.java b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/FiltersPackage.java index 7078f2d5cd3..b5cecb0a7e3 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/FiltersPackage.java +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/FiltersPackage.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2014 Christian W. Damus and others. + * Copyright (c) 2014, 2021 Christian W. Damus, CEA LIST, and others. * * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License 2.0 @@ -135,7 +135,100 @@ public interface FiltersPackage extends EPackage { * @see org.eclipse.papyrus.infra.filters.impl.FiltersPackageImpl#getCompoundFilter() * @generated */ - int COMPOUND_FILTER = 0; + int COMPOUND_FILTER = 2; + + /** + * The meta object id for the '{@link org.eclipse.papyrus.infra.filters.impl.EqualsImpl <em>Equals</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @see org.eclipse.papyrus.infra.filters.impl.EqualsImpl + * @see org.eclipse.papyrus.infra.filters.impl.FiltersPackageImpl#getEquals() + * @generated + */ + int EQUALS = 3; + + /** + * The meta object id for the '{@link org.eclipse.papyrus.infra.filters.impl.FilteredElementImpl <em>Filtered Element</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @see org.eclipse.papyrus.infra.filters.impl.FilteredElementImpl + * @see org.eclipse.papyrus.infra.filters.impl.FiltersPackageImpl#getFilteredElement() + * @generated + */ + int FILTERED_ELEMENT = 4; + + /** + * The meta object id for the '{@link org.eclipse.papyrus.infra.filters.impl.FilterReferenceImpl <em>Filter Reference</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @see org.eclipse.papyrus.infra.filters.impl.FilterReferenceImpl + * @see org.eclipse.papyrus.infra.filters.impl.FiltersPackageImpl#getFilterReference() + * @generated + */ + int FILTER_REFERENCE = 0; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + * @ordered + */ + int FILTER_REFERENCE__NAME = FILTER__NAME; + + /** + * The feature id for the '<em><b>Filter</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + * @ordered + */ + int FILTER_REFERENCE__FILTER = FILTER_FEATURE_COUNT + 0; + + /** + * The feature id for the '<em><b>Owned Filter</b></em>' containment reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + * @ordered + */ + int FILTER_REFERENCE__OWNED_FILTER = FILTER_FEATURE_COUNT + 1; + + /** + * The number of structural features of the '<em>Filter Reference</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + * @ordered + */ + int FILTER_REFERENCE_FEATURE_COUNT = FILTER_FEATURE_COUNT + 2; + + /** + * The operation id for the '<em>Matches</em>' operation. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + * @ordered + */ + int FILTER_REFERENCE___MATCHES__OBJECT = FILTER___MATCHES__OBJECT; + + /** + * The number of operations of the '<em>Filter Reference</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + * @ordered + */ + int FILTER_REFERENCE_OPERATION_COUNT = FILTER_OPERATION_COUNT + 0; /** * The feature id for the '<em><b>Name</b></em>' attribute. @@ -218,17 +311,6 @@ public interface FiltersPackage extends EPackage { int COMPOUND_FILTER_OPERATION_COUNT = FILTER_OPERATION_COUNT + 1; /** - * The meta object id for the '{@link org.eclipse.papyrus.infra.filters.impl.EqualsImpl <em>Equals</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.infra.filters.impl.EqualsImpl - * @see org.eclipse.papyrus.infra.filters.impl.FiltersPackageImpl#getEquals() - * @generated - */ - int EQUALS = 2; - - /** * The feature id for the '<em><b>Name</b></em>' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> @@ -279,25 +361,12 @@ public interface FiltersPackage extends EPackage { int EQUALS_OPERATION_COUNT = FILTER_OPERATION_COUNT + 0; /** - * The meta object id for the '{@link org.eclipse.papyrus.infra.filters.impl.FilteredElementImpl <em>Filtered Element</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.infra.filters.impl.FilteredElementImpl - * @see org.eclipse.papyrus.infra.filters.impl.FiltersPackageImpl#getFilteredElement() - * @generated - * @since 1.3 - */ - int FILTERED_ELEMENT = 3; - - /** * The feature id for the '<em><b>Filter</b></em>' containment reference. * <!-- begin-user-doc --> * <!-- end-user-doc --> * * @generated * @ordered - * @since 1.3 */ int FILTERED_ELEMENT__FILTER = 0; @@ -308,7 +377,6 @@ public interface FiltersPackage extends EPackage { * * @generated * @ordered - * @since 1.3 */ int FILTERED_ELEMENT_FEATURE_COUNT = 1; @@ -319,7 +387,6 @@ public interface FiltersPackage extends EPackage { * * @generated * @ordered - * @since 1.3 */ int FILTERED_ELEMENT_OPERATION_COUNT = 0; @@ -332,7 +399,7 @@ public interface FiltersPackage extends EPackage { * @see org.eclipse.papyrus.infra.filters.impl.FiltersPackageImpl#getOperatorKind() * @generated */ - int OPERATOR_KIND = 4; + int OPERATOR_KIND = 5; /** * The meta object id for the '<em>Object</em>' data type. @@ -343,7 +410,7 @@ public interface FiltersPackage extends EPackage { * @see org.eclipse.papyrus.infra.filters.impl.FiltersPackageImpl#getObject() * @generated */ - int OBJECT = 5; + int OBJECT = 6; /** @@ -469,7 +536,6 @@ public interface FiltersPackage extends EPackage { * @return the meta object for class '<em>Filtered Element</em>'. * @see org.eclipse.papyrus.infra.filters.FilteredElement * @generated - * @since 1.3 */ EClass getFilteredElement(); @@ -482,11 +548,45 @@ public interface FiltersPackage extends EPackage { * @see org.eclipse.papyrus.infra.filters.FilteredElement#getFilter() * @see #getFilteredElement() * @generated - * @since 1.3 */ EReference getFilteredElement_Filter(); /** + * Returns the meta object for class '{@link org.eclipse.papyrus.infra.filters.FilterReference <em>Filter Reference</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @return the meta object for class '<em>Filter Reference</em>'. + * @see org.eclipse.papyrus.infra.filters.FilterReference + * @generated + */ + EClass getFilterReference(); + + /** + * Returns the meta object for the reference '{@link org.eclipse.papyrus.infra.filters.FilterReference#getFilter <em>Filter</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @return the meta object for the reference '<em>Filter</em>'. + * @see org.eclipse.papyrus.infra.filters.FilterReference#getFilter() + * @see #getFilterReference() + * @generated + */ + EReference getFilterReference_Filter(); + + /** + * Returns the meta object for the containment reference '{@link org.eclipse.papyrus.infra.filters.FilterReference#getOwnedFilter <em>Owned Filter</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @return the meta object for the containment reference '<em>Owned Filter</em>'. + * @see org.eclipse.papyrus.infra.filters.FilterReference#getOwnedFilter() + * @see #getFilterReference() + * @generated + */ + EReference getFilterReference_OwnedFilter(); + + /** * Returns the meta object for enum '{@link org.eclipse.papyrus.infra.filters.OperatorKind <em>Operator Kind</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> @@ -638,7 +738,6 @@ public interface FiltersPackage extends EPackage { * @see org.eclipse.papyrus.infra.filters.impl.FilteredElementImpl * @see org.eclipse.papyrus.infra.filters.impl.FiltersPackageImpl#getFilteredElement() * @generated - * @since 1.3 */ EClass FILTERED_ELEMENT = eINSTANCE.getFilteredElement(); @@ -648,11 +747,39 @@ public interface FiltersPackage extends EPackage { * <!-- end-user-doc --> * * @generated - * @since 1.3 */ EReference FILTERED_ELEMENT__FILTER = eINSTANCE.getFilteredElement_Filter(); /** + * The meta object literal for the '{@link org.eclipse.papyrus.infra.filters.impl.FilterReferenceImpl <em>Filter Reference</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @see org.eclipse.papyrus.infra.filters.impl.FilterReferenceImpl + * @see org.eclipse.papyrus.infra.filters.impl.FiltersPackageImpl#getFilterReference() + * @generated + */ + EClass FILTER_REFERENCE = eINSTANCE.getFilterReference(); + + /** + * The meta object literal for the '<em><b>Filter</b></em>' reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + EReference FILTER_REFERENCE__FILTER = eINSTANCE.getFilterReference_Filter(); + + /** + * The meta object literal for the '<em><b>Owned Filter</b></em>' containment reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + EReference FILTER_REFERENCE__OWNED_FILTER = eINSTANCE.getFilterReference_OwnedFilter(); + + /** * The meta object literal for the '{@link org.eclipse.papyrus.infra.filters.OperatorKind <em>Operator Kind</em>}' enum. * <!-- begin-user-doc --> * <!-- end-user-doc --> diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/OperatorKind.java b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/OperatorKind.java index 769af64b8d8..07d2c96a2f6 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/OperatorKind.java +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/OperatorKind.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2014 Christian W. Damus and others. + * Copyright (c) 2014, 2021 Christian W. Damus, CEA LIST, and others. * * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License 2.0 @@ -163,7 +163,7 @@ public enum OperatorKind implements Enumerator { * <!-- end-user-doc --> * * @param literal - * the literal. + * the literal. * @return the matching enumerator or <code>null</code>. * @generated */ @@ -183,7 +183,7 @@ public enum OperatorKind implements Enumerator { * <!-- end-user-doc --> * * @param name - * the name. + * the name. * @return the matching enumerator or <code>null</code>. * @generated */ @@ -203,7 +203,7 @@ public enum OperatorKind implements Enumerator { * <!-- end-user-doc --> * * @param value - * the integer value. + * the integer value. * @return the matching enumerator or <code>null</code>. * @generated */ diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/impl/CompoundFilterImpl.java b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/impl/CompoundFilterImpl.java index 564cbbc96cc..88c6b28b26c 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/impl/CompoundFilterImpl.java +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/impl/CompoundFilterImpl.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2014 Christian W. Damus and others. + * Copyright (c) 2014, 2021 Christian W. Damus, CEA LIST, and others. * * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License 2.0 @@ -525,7 +525,7 @@ public class CompoundFilterImpl extends MinimalEObjectImpl.Container implements return super.toString(); } - StringBuffer result = new StringBuffer(super.toString()); + StringBuilder result = new StringBuilder(super.toString()); result.append(" (name: "); //$NON-NLS-1$ result.append(name); result.append(", operator: "); //$NON-NLS-1$ @@ -540,7 +540,7 @@ public class CompoundFilterImpl extends MinimalEObjectImpl.Container implements * <!-- end-user-doc --> * * @param eClass - * The Ecore class of the instance to create. + * The Ecore class of the instance to create. * @return The new instance. * @generated */ diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/impl/EqualsImpl.java b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/impl/EqualsImpl.java index 2fb584c4776..2aac047ca75 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/impl/EqualsImpl.java +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/impl/EqualsImpl.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2014 Christian W. Damus and others. + * Copyright (c) 2014, 2021 Christian W. Damus, CEA LIST, and others. * * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License 2.0 @@ -281,7 +281,7 @@ public class EqualsImpl extends MinimalEObjectImpl.Container implements Equals { return super.toString(); } - StringBuffer result = new StringBuffer(super.toString()); + StringBuilder result = new StringBuilder(super.toString()); result.append(" (name: "); //$NON-NLS-1$ result.append(name); result.append(", object: "); //$NON-NLS-1$ @@ -296,7 +296,7 @@ public class EqualsImpl extends MinimalEObjectImpl.Container implements Equals { * <!-- end-user-doc --> * * @param eClass - * The Ecore class of the instance to create. + * The Ecore class of the instance to create. * @return The new instance. * @generated */ diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/impl/FilterReferenceImpl.java b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/impl/FilterReferenceImpl.java new file mode 100644 index 00000000000..1e10cd756d1 --- /dev/null +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/impl/FilterReferenceImpl.java @@ -0,0 +1,447 @@ +/** + * Copyright (c) 2021 Christian W. Damus, CEA LIST, and others. + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the Eclipse Public License 2.0 + * which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-2.0/ + * + * SPDX-License-Identifier: EPL-2.0 + * + * Contributors: + * Christian W. Damus - Initial API and implementation + */ +package org.eclipse.papyrus.infra.filters.impl; + +import java.lang.reflect.InvocationTargetException; + +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.EObject; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; +import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; + +import org.eclipse.emf.ecore.resource.Resource; +import org.eclipse.emf.ecore.util.EcoreUtil; + +import org.eclipse.papyrus.infra.filters.Filter; +import org.eclipse.papyrus.infra.filters.FilterReference; +import org.eclipse.papyrus.infra.filters.FiltersPackage; + +import org.eclipse.papyrus.infra.filters.internal.operations.FilterReferenceOperations; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Filter Reference</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * </p> + * <ul> + * <li>{@link org.eclipse.papyrus.infra.filters.impl.FilterReferenceImpl#getName <em>Name</em>}</li> + * <li>{@link org.eclipse.papyrus.infra.filters.impl.FilterReferenceImpl#getFilter <em>Filter</em>}</li> + * <li>{@link org.eclipse.papyrus.infra.filters.impl.FilterReferenceImpl#getOwnedFilter <em>Owned Filter</em>}</li> + * </ul> + * + * @generated + */ +public class FilterReferenceImpl extends MinimalEObjectImpl.Container implements FilterReference { + /** + * A set of bit flags representing the values of boolean attributes and whether unsettable features have been set. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + * @ordered + */ + protected int _flags = 0; + + /** + * The default value of the '{@link #getName() <em>Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @see #getName() + * @generated + * @ordered + */ + protected static final String NAME_EDEFAULT = null; + + /** + * The cached value of the '{@link #getName() <em>Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @see #getName() + * @generated + * @ordered + */ + protected String name = NAME_EDEFAULT; + + /** + * The cached value of the '{@link #getFilter() <em>Filter</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @see #getFilter() + * @generated + * @ordered + */ + protected Filter filter; + + /** + * The cached value of the '{@link #getOwnedFilter() <em>Owned Filter</em>}' containment reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @see #getOwnedFilter() + * @generated + * @ordered + */ + protected Filter ownedFilter; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + protected FilterReferenceImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return FiltersPackage.Literals.FILTER_REFERENCE; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override + public String getName() { + return name; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override + public void setName(String newName) { + newName = newName == null ? NAME_EDEFAULT : newName; + String oldName = name; + name = newName; + if (eNotificationRequired()) { + eNotify(new ENotificationImpl(this, Notification.SET, FiltersPackage.FILTER_REFERENCE__NAME, oldName, name)); + } + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override + public Filter getFilter() { + if (filter != null && filter.eIsProxy()) { + InternalEObject oldFilter = (InternalEObject) filter; + filter = (Filter) eResolveProxy(oldFilter); + if (filter != oldFilter) { + if (eNotificationRequired()) { + eNotify(new ENotificationImpl(this, Notification.RESOLVE, FiltersPackage.FILTER_REFERENCE__FILTER, oldFilter, filter)); + } + } + } + return filter; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + public Filter basicGetFilter() { + return filter; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override + public void setFilter(Filter newFilter) { + Filter oldFilter = filter; + filter = newFilter; + if (eNotificationRequired()) { + eNotify(new ENotificationImpl(this, Notification.SET, FiltersPackage.FILTER_REFERENCE__FILTER, oldFilter, filter)); + } + Resource.Internal eInternalResource = eInternalResource(); + if (eInternalResource == null || !eInternalResource.isLoading()) { + if (ownedFilter != null && ownedFilter != newFilter) { + setOwnedFilter(null); + } + } + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override + public Filter getOwnedFilter() { + return ownedFilter; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + public NotificationChain basicSetOwnedFilter(Filter newOwnedFilter, NotificationChain msgs) { + Filter oldOwnedFilter = ownedFilter; + ownedFilter = newOwnedFilter; + if (eNotificationRequired()) { + ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, FiltersPackage.FILTER_REFERENCE__OWNED_FILTER, oldOwnedFilter, newOwnedFilter); + if (msgs == null) { + msgs = notification; + } else { + msgs.add(notification); + } + } + Resource.Internal eInternalResource = eInternalResource(); + if (eInternalResource == null || !eInternalResource.isLoading()) { + if (newOwnedFilter != null) { + if (newOwnedFilter != filter) { + setFilter(newOwnedFilter); + } + } + } + return msgs; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override + public void setOwnedFilter(Filter newOwnedFilter) { + if (newOwnedFilter != ownedFilter) { + NotificationChain msgs = null; + if (ownedFilter != null) { + msgs = ((InternalEObject) ownedFilter).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - FiltersPackage.FILTER_REFERENCE__OWNED_FILTER, null, msgs); + } + if (newOwnedFilter != null) { + msgs = ((InternalEObject) newOwnedFilter).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - FiltersPackage.FILTER_REFERENCE__OWNED_FILTER, null, msgs); + } + msgs = basicSetOwnedFilter(newOwnedFilter, msgs); + if (msgs != null) { + msgs.dispatch(); + } + } else if (eNotificationRequired()) { + eNotify(new ENotificationImpl(this, Notification.SET, FiltersPackage.FILTER_REFERENCE__OWNED_FILTER, newOwnedFilter, newOwnedFilter)); + } + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override + public Filter createOwnedFilter(String name, EClass eClass) { + Filter newOwnedFilter = (Filter) create(eClass); + setOwnedFilter(newOwnedFilter); + if (name != null) { + newOwnedFilter.setName(name); + } + return newOwnedFilter; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override + public boolean matches(Object input) { + return FilterReferenceOperations.matches(this, input); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case FiltersPackage.FILTER_REFERENCE__OWNED_FILTER: + return basicSetOwnedFilter(null, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case FiltersPackage.FILTER_REFERENCE__NAME: + return getName(); + case FiltersPackage.FILTER_REFERENCE__FILTER: + if (resolve) { + return getFilter(); + } + return basicGetFilter(); + case FiltersPackage.FILTER_REFERENCE__OWNED_FILTER: + return getOwnedFilter(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case FiltersPackage.FILTER_REFERENCE__NAME: + setName((String) newValue); + return; + case FiltersPackage.FILTER_REFERENCE__FILTER: + setFilter((Filter) newValue); + return; + case FiltersPackage.FILTER_REFERENCE__OWNED_FILTER: + setOwnedFilter((Filter) newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case FiltersPackage.FILTER_REFERENCE__NAME: + setName(NAME_EDEFAULT); + return; + case FiltersPackage.FILTER_REFERENCE__FILTER: + setFilter((Filter) null); + return; + case FiltersPackage.FILTER_REFERENCE__OWNED_FILTER: + setOwnedFilter((Filter) null); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case FiltersPackage.FILTER_REFERENCE__NAME: + return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name); + case FiltersPackage.FILTER_REFERENCE__FILTER: + return filter != null; + case FiltersPackage.FILTER_REFERENCE__OWNED_FILTER: + return ownedFilter != null; + } + return super.eIsSet(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override + public Object eInvoke(int operationID, EList<?> arguments) throws InvocationTargetException { + switch (operationID) { + case FiltersPackage.FILTER_REFERENCE___MATCHES__OBJECT: + return matches(arguments.get(0)); + } + return super.eInvoke(operationID, arguments); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override + public String toString() { + if (eIsProxy()) { + return super.toString(); + } + + StringBuilder result = new StringBuilder(super.toString()); + result.append(" (name: "); //$NON-NLS-1$ + result.append(name); + result.append(')'); + return result.toString(); + } + + /** + * Creates a new instance of the specified Ecore class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @param eClass + * The Ecore class of the instance to create. + * @return The new instance. + * @generated + */ + protected EObject create(EClass eClass) { + return EcoreUtil.create(eClass); + } + +} // FilterReferenceImpl diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/impl/FilteredElementImpl.java b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/impl/FilteredElementImpl.java index bf0f351c0de..657e951effb 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/impl/FilteredElementImpl.java +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/impl/FilteredElementImpl.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2014 Christian W. Damus and others. + * Copyright (c) 2014, 2021 Christian W. Damus, CEA LIST, and others. * * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License 2.0 @@ -41,7 +41,6 @@ import org.eclipse.papyrus.infra.filters.FiltersPackage; * </ul> * * @generated - * @since 1.3 */ public class FilteredElementImpl extends MinimalEObjectImpl.Container implements FilteredElement { /** @@ -241,7 +240,7 @@ public class FilteredElementImpl extends MinimalEObjectImpl.Container implements * <!-- end-user-doc --> * * @param eClass - * The Ecore class of the instance to create. + * The Ecore class of the instance to create. * @return The new instance. * @generated */ diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/impl/FiltersFactoryImpl.java b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/impl/FiltersFactoryImpl.java index 857dd252da8..7853e5bc59a 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/impl/FiltersFactoryImpl.java +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/impl/FiltersFactoryImpl.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2014 Christian W. Damus and others. + * Copyright (c) 2014, 2021 Christian W. Damus, CEA LIST, and others. * * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License 2.0 @@ -71,6 +71,8 @@ public class FiltersFactoryImpl extends EFactoryImpl implements FiltersFactory { @Override public EObject create(EClass eClass) { switch (eClass.getClassifierID()) { + case FiltersPackage.FILTER_REFERENCE: + return createFilterReference(); case FiltersPackage.COMPOUND_FILTER: return createCompoundFilter(); case FiltersPackage.EQUALS: @@ -160,6 +162,18 @@ public class FiltersFactoryImpl extends EFactoryImpl implements FiltersFactory { * * @generated */ + @Override + public FilterReference createFilterReference() { + FilterReferenceImpl filterReference = new FilterReferenceImpl(); + return filterReference; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ public OperatorKind createOperatorKindFromString(EDataType eDataType, String initialValue) { OperatorKind result = OperatorKind.get(initialValue); if (result == null) diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/impl/FiltersPackageImpl.java b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/impl/FiltersPackageImpl.java index 7a3e25f258f..6cf26216480 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/impl/FiltersPackageImpl.java +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/impl/FiltersPackageImpl.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2014 Christian W. Damus and others. + * Copyright (c) 2014, 2021 Christian W. Damus, CEA LIST, and others. * * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License 2.0 @@ -27,6 +27,7 @@ import org.eclipse.emf.ecore.impl.EPackageImpl; import org.eclipse.papyrus.infra.filters.CompoundFilter; import org.eclipse.papyrus.infra.filters.Equals; import org.eclipse.papyrus.infra.filters.Filter; +import org.eclipse.papyrus.infra.filters.FilterReference; import org.eclipse.papyrus.infra.filters.FilteredElement; import org.eclipse.papyrus.infra.filters.FiltersFactory; import org.eclipse.papyrus.infra.filters.FiltersPackage; @@ -80,6 +81,14 @@ public class FiltersPackageImpl extends EPackageImpl implements FiltersPackage { * * @generated */ + private EClass filterReferenceEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ private EEnum operatorKindEEnum = null; /** @@ -137,7 +146,8 @@ public class FiltersPackageImpl extends EPackageImpl implements FiltersPackage { } // Obtain or create and register package - FiltersPackageImpl theFiltersPackage = (FiltersPackageImpl) (EPackage.Registry.INSTANCE.get(eNS_URI) instanceof FiltersPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) : new FiltersPackageImpl()); + Object registeredFiltersPackage = EPackage.Registry.INSTANCE.get(eNS_URI); + FiltersPackageImpl theFiltersPackage = registeredFiltersPackage instanceof FiltersPackageImpl ? (FiltersPackageImpl) registeredFiltersPackage : new FiltersPackageImpl(); isInited = true; @@ -162,7 +172,6 @@ public class FiltersPackageImpl extends EPackageImpl implements FiltersPackage { // Mark meta-data to indicate it can't be changed theFiltersPackage.freeze(); - // Update the registry and return the package EPackage.Registry.INSTANCE.put(FiltersPackage.eNS_URI, theFiltersPackage); return theFiltersPackage; @@ -307,6 +316,39 @@ public class FiltersPackageImpl extends EPackageImpl implements FiltersPackage { * @generated */ @Override + public EClass getFilterReference() { + return filterReferenceEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override + public EReference getFilterReference_Filter() { + return (EReference) filterReferenceEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override + public EReference getFilterReference_OwnedFilter() { + return (EReference) filterReferenceEClass.getEStructuralFeatures().get(1); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + @Override public EEnum getOperatorKind() { return operatorKindEEnum; } @@ -356,16 +398,20 @@ public class FiltersPackageImpl extends EPackageImpl implements FiltersPackage { isCreated = true; // Create classes and their features + filterReferenceEClass = createEClass(FILTER_REFERENCE); + createEReference(filterReferenceEClass, FILTER_REFERENCE__FILTER); + createEReference(filterReferenceEClass, FILTER_REFERENCE__OWNED_FILTER); + + filterEClass = createEClass(FILTER); + createEAttribute(filterEClass, FILTER__NAME); + createEOperation(filterEClass, FILTER___MATCHES__OBJECT); + compoundFilterEClass = createEClass(COMPOUND_FILTER); createEReference(compoundFilterEClass, COMPOUND_FILTER__FILTER); createEReference(compoundFilterEClass, COMPOUND_FILTER__OWNED_FILTER); createEAttribute(compoundFilterEClass, COMPOUND_FILTER__OPERATOR); createEOperation(compoundFilterEClass, COMPOUND_FILTER___VALIDATE_ACYCLIC__DIAGNOSTICCHAIN_MAP); - filterEClass = createEClass(FILTER); - createEAttribute(filterEClass, FILTER__NAME); - createEOperation(filterEClass, FILTER___MATCHES__OBJECT); - equalsEClass = createEClass(EQUALS); createEAttribute(equalsEClass, EQUALS__OBJECT); @@ -414,17 +460,29 @@ public class FiltersPackageImpl extends EPackageImpl implements FiltersPackage { // Set bounds for type parameters // Add supertypes to classes + filterReferenceEClass.getESuperTypes().add(this.getFilter()); compoundFilterEClass.getESuperTypes().add(this.getFilter()); equalsEClass.getESuperTypes().add(this.getFilter()); // Initialize classes, features, and operations; add parameters + initEClass(filterReferenceEClass, FilterReference.class, "FilterReference", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); //$NON-NLS-1$ + initEReference(getFilterReference_Filter(), this.getFilter(), null, "filter", null, 1, 1, FilterReference.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); //$NON-NLS-1$ + initEReference(getFilterReference_OwnedFilter(), this.getFilter(), null, "ownedFilter", null, 0, 1, FilterReference.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, //$NON-NLS-1$ + !IS_ORDERED); + + initEClass(filterEClass, Filter.class, "Filter", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); //$NON-NLS-1$ + initEAttribute(getFilter_Name(), theTypesPackage.getString(), "name", null, 0, 1, Filter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); //$NON-NLS-1$ + + EOperation op = initEOperation(getFilter__Matches__Object(), theTypesPackage.getBoolean(), "matches", 1, 1, IS_UNIQUE, !IS_ORDERED); //$NON-NLS-1$ + addEParameter(op, this.getObject(), "input", 1, 1, IS_UNIQUE, !IS_ORDERED); //$NON-NLS-1$ + initEClass(compoundFilterEClass, CompoundFilter.class, "CompoundFilter", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); //$NON-NLS-1$ initEReference(getCompoundFilter_Filter(), this.getFilter(), null, "filter", null, 1, -1, CompoundFilter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); //$NON-NLS-1$ initEReference(getCompoundFilter_OwnedFilter(), this.getFilter(), null, "ownedFilter", null, 0, -1, CompoundFilter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, //$NON-NLS-1$ !IS_ORDERED); initEAttribute(getCompoundFilter_Operator(), this.getOperatorKind(), "operator", null, 1, 1, CompoundFilter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); //$NON-NLS-1$ - EOperation op = initEOperation(getCompoundFilter__ValidateAcyclic__DiagnosticChain_Map(), ecorePackage.getEBoolean(), "validateAcyclic", 0, 1, IS_UNIQUE, IS_ORDERED); //$NON-NLS-1$ + op = initEOperation(getCompoundFilter__ValidateAcyclic__DiagnosticChain_Map(), ecorePackage.getEBoolean(), "validateAcyclic", 0, 1, IS_UNIQUE, IS_ORDERED); //$NON-NLS-1$ addEParameter(op, ecorePackage.getEDiagnosticChain(), "diagnostics", 0, 1, IS_UNIQUE, IS_ORDERED); //$NON-NLS-1$ EGenericType g1 = createEGenericType(ecorePackage.getEMap()); EGenericType g2 = createEGenericType(ecorePackage.getEJavaObject()); @@ -433,12 +491,6 @@ public class FiltersPackageImpl extends EPackageImpl implements FiltersPackage { g1.getETypeArguments().add(g2); addEParameter(op, g1, "context", 0, 1, IS_UNIQUE, IS_ORDERED); //$NON-NLS-1$ - initEClass(filterEClass, Filter.class, "Filter", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); //$NON-NLS-1$ - initEAttribute(getFilter_Name(), theTypesPackage.getString(), "name", null, 0, 1, Filter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); //$NON-NLS-1$ - - op = initEOperation(getFilter__Matches__Object(), theTypesPackage.getBoolean(), "matches", 1, 1, IS_UNIQUE, !IS_ORDERED); //$NON-NLS-1$ - addEParameter(op, this.getObject(), "input", 1, 1, IS_UNIQUE, !IS_ORDERED); //$NON-NLS-1$ - initEClass(equalsEClass, Equals.class, "Equals", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); //$NON-NLS-1$ initEAttribute(getEquals_Object(), this.getObject(), "object", null, 1, 1, Equals.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); //$NON-NLS-1$ @@ -472,6 +524,13 @@ public class FiltersPackageImpl extends EPackageImpl implements FiltersPackage { */ protected void createSubsetsAnnotations() { String source = "subsets"; //$NON-NLS-1$ + addAnnotation(getFilterReference_OwnedFilter(), + source, + new String[] { + }, + new URI[] { + URI.createURI(eNS_URI).appendFragment("//FilterReference/filter") //$NON-NLS-1$ + }); addAnnotation(getCompoundFilter_OwnedFilter(), source, new String[] { diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/internal/operations/CompoundFilterOperations.java b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/internal/operations/CompoundFilterOperations.java index be162b462c2..43ff69d437f 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/internal/operations/CompoundFilterOperations.java +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/internal/operations/CompoundFilterOperations.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2014 Christian W. Damus and others. + * Copyright (c) 2014, 2021 Christian W. Damus, CEA LIST, and others. * * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License 2.0 @@ -115,18 +115,18 @@ public class CompoundFilterOperations { * A filter may not directly or indirectly compose itself. * * @param compoundFilter - * The receiving '<em><b>Composite Filter</b></em>' model object. + * The receiving '<em><b>Composite Filter</b></em>' model object. * @param diagnostics - * The chain of diagnostics to which problems are to be appended. + * The chain of diagnostics to which problems are to be appended. * @param context - * The cache of context-specific information. - * <!-- end-model-doc --> + * The cache of context-specific information. + * <!-- end-model-doc --> * @generated NOT */ public static boolean validateAcyclic(final CompoundFilter compoundFilter, DiagnosticChain diagnostics, Map<Object, Object> context) { boolean result = true; - Iterator<Filter> allFilters = new AbstractTreeIterator<Filter>(compoundFilter, false) { + Iterator<Filter> allFilters = new AbstractTreeIterator<>(compoundFilter, false) { private static final long serialVersionUID = 1L; @Override @@ -153,4 +153,4 @@ public class CompoundFilterOperations { return result; } -} // CompoundFilterOperations
\ No newline at end of file +} // CompoundFilterOperations diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/internal/operations/FilterReferenceOperations.java b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/internal/operations/FilterReferenceOperations.java new file mode 100644 index 00000000000..253e646784d --- /dev/null +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/internal/operations/FilterReferenceOperations.java @@ -0,0 +1,55 @@ +/** + * Copyright (c) 2021 Christian W. Damus, CEA LIST, and others. + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the Eclipse Public License 2.0 + * which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-2.0/ + * + * SPDX-License-Identifier: EPL-2.0 + * + * Contributors: + * Christian W. Damus - Initial API and implementation + */ +package org.eclipse.papyrus.infra.filters.internal.operations; + +import org.eclipse.papyrus.infra.filters.Filter; +import org.eclipse.papyrus.infra.filters.FilterReference; + +/** + * <!-- begin-user-doc --> + * A static utility class that provides operations related to '<em><b>Filter Reference</b></em>' model objects. + * <!-- end-user-doc --> + * + * <p> + * The following operations are supported: + * </p> + * <ul> + * <li>{@link org.eclipse.papyrus.infra.filters.Filter#matches(java.lang.Object) <em>Matches</em>}</li> + * </ul> + * + * @generated + */ +public class FilterReferenceOperations { + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ + protected FilterReferenceOperations() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated NOT + */ + public static boolean matches(FilterReference filterReference, Object input) { + Filter referenced = filterReference.getFilter(); + return referenced != null && referenced.matches(input); + } + +} // FilterReferenceOperations diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/util/FiltersAdapterFactory.java b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/util/FiltersAdapterFactory.java index 53b7d20be54..15ab60fee51 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/util/FiltersAdapterFactory.java +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/util/FiltersAdapterFactory.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2014 Christian W. Damus and others. + * Copyright (c) 2014, 2021 Christian W. Damus, CEA LIST, and others. * * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License 2.0 @@ -81,10 +81,10 @@ public class FiltersAdapterFactory extends AdapterFactoryImpl { * * @generated */ - protected FiltersSwitch<Adapter> modelSwitch = new FiltersSwitch<Adapter>() { + protected FiltersSwitch<Adapter> modelSwitch = new FiltersSwitch<>() { @Override - public Adapter caseCompoundFilter(CompoundFilter object) { - return createCompoundFilterAdapter(); + public Adapter caseFilterReference(FilterReference object) { + return createFilterReferenceAdapter(); } @Override @@ -93,6 +93,11 @@ public class FiltersAdapterFactory extends AdapterFactoryImpl { } @Override + public Adapter caseCompoundFilter(CompoundFilter object) { + return createCompoundFilterAdapter(); + } + + @Override public Adapter caseEquals(Equals object) { return createEqualsAdapter(); } @@ -114,7 +119,7 @@ public class FiltersAdapterFactory extends AdapterFactoryImpl { * <!-- end-user-doc --> * * @param target - * the object to adapt. + * the object to adapt. * @return the adapter for the <code>target</code>. * @generated */ @@ -179,13 +184,27 @@ public class FiltersAdapterFactory extends AdapterFactoryImpl { * @return the new adapter. * @see org.eclipse.papyrus.infra.filters.FilteredElement * @generated - * @since 1.3 */ public Adapter createFilteredElementAdapter() { return null; } /** + * Creates a new adapter for an object of class '{@link org.eclipse.papyrus.infra.filters.FilterReference <em>Filter Reference</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * + * @return the new adapter. + * @see org.eclipse.papyrus.infra.filters.FilterReference + * @generated + */ + public Adapter createFilterReferenceAdapter() { + return null; + } + + /** * Creates a new adapter for the default case. * <!-- begin-user-doc --> * This default implementation returns null. diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/util/FiltersSwitch.java b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/util/FiltersSwitch.java index fbc8766c312..fc88587810f 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/util/FiltersSwitch.java +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/util/FiltersSwitch.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2014 Christian W. Damus and others. + * Copyright (c) 2014, 2021 Christian W. Damus, CEA LIST, and others. * * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License 2.0 @@ -62,7 +62,7 @@ public class FiltersSwitch<T> extends Switch<T> { * <!-- end-user-doc --> * * @param ePackage - * the package in question. + * the package in question. * @return whether this is a switch for the given package. * @generated */ @@ -82,11 +82,11 @@ public class FiltersSwitch<T> extends Switch<T> { @Override protected T doSwitch(int classifierID, EObject theEObject) { switch (classifierID) { - case FiltersPackage.COMPOUND_FILTER: { - CompoundFilter compoundFilter = (CompoundFilter) theEObject; - T result = caseCompoundFilter(compoundFilter); + case FiltersPackage.FILTER_REFERENCE: { + FilterReference filterReference = (FilterReference) theEObject; + T result = caseFilterReference(filterReference); if (result == null) { - result = caseFilter(compoundFilter); + result = caseFilter(filterReference); } if (result == null) { result = defaultCase(theEObject); @@ -101,6 +101,17 @@ public class FiltersSwitch<T> extends Switch<T> { } return result; } + case FiltersPackage.COMPOUND_FILTER: { + CompoundFilter compoundFilter = (CompoundFilter) theEObject; + T result = caseCompoundFilter(compoundFilter); + if (result == null) { + result = caseFilter(compoundFilter); + } + if (result == null) { + result = defaultCase(theEObject); + } + return result; + } case FiltersPackage.EQUALS: { Equals equals = (Equals) theEObject; T result = caseEquals(equals); @@ -133,7 +144,7 @@ public class FiltersSwitch<T> extends Switch<T> { * <!-- end-user-doc --> * * @param object - * the target of the switch. + * the target of the switch. * @return the result of interpreting the object as an instance of '<em>Compound Filter</em>'. * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) * @generated @@ -150,7 +161,7 @@ public class FiltersSwitch<T> extends Switch<T> { * <!-- end-user-doc --> * * @param object - * the target of the switch. + * the target of the switch. * @return the result of interpreting the object as an instance of '<em>Filter</em>'. * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) * @generated @@ -167,7 +178,7 @@ public class FiltersSwitch<T> extends Switch<T> { * <!-- end-user-doc --> * * @param object - * the target of the switch. + * the target of the switch. * @return the result of interpreting the object as an instance of '<em>Equals</em>'. * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) * @generated @@ -184,17 +195,33 @@ public class FiltersSwitch<T> extends Switch<T> { * <!-- end-user-doc --> * * @param object - * the target of the switch. + * the target of the switch. * @return the result of interpreting the object as an instance of '<em>Filtered Element</em>'. * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) * @generated - * @since 1.3 */ public T caseFilteredElement(FilteredElement object) { return null; } /** + * Returns the result of interpreting the object as an instance of '<em>Filter Reference</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * + * @param object + * the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Filter Reference</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseFilterReference(FilterReference object) { + return null; + } + + /** * Returns the result of interpreting the object as an instance of '<em>EObject</em>'. * <!-- begin-user-doc --> * This implementation returns null; @@ -202,7 +229,7 @@ public class FiltersSwitch<T> extends Switch<T> { * <!-- end-user-doc --> * * @param object - * the target of the switch. + * the target of the switch. * @return the result of interpreting the object as an instance of '<em>EObject</em>'. * @see #doSwitch(org.eclipse.emf.ecore.EObject) * @generated diff --git a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/util/FiltersValidator.java b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/util/FiltersValidator.java index a3402c5e30d..d048192560e 100644 --- a/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/util/FiltersValidator.java +++ b/plugins/infra/filters/org.eclipse.papyrus.infra.filters/src-gen/org/eclipse/papyrus/infra/filters/util/FiltersValidator.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2014 Christian W. Damus and others. + * Copyright (c) 2014, 2021 Christian W. Damus, CEA LIST, and others. * * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License 2.0 @@ -116,10 +116,12 @@ public class FiltersValidator extends EObjectValidator { @Override protected boolean validate(int classifierID, Object value, DiagnosticChain diagnostics, Map<Object, Object> context) { switch (classifierID) { - case FiltersPackage.COMPOUND_FILTER: - return validateCompoundFilter((CompoundFilter) value, diagnostics, context); + case FiltersPackage.FILTER_REFERENCE: + return validateFilterReference((FilterReference) value, diagnostics, context); case FiltersPackage.FILTER: return validateFilter((Filter) value, diagnostics, context); + case FiltersPackage.COMPOUND_FILTER: + return validateCompoundFilter((CompoundFilter) value, diagnostics, context); case FiltersPackage.EQUALS: return validateEquals((Equals) value, diagnostics, context); case FiltersPackage.FILTERED_ELEMENT: @@ -207,7 +209,6 @@ public class FiltersValidator extends EObjectValidator { * <!-- end-user-doc --> * * @generated - * @since 1.3 */ public boolean validateFilteredElement(FilteredElement filteredElement, DiagnosticChain diagnostics, Map<Object, Object> context) { return validate_EveryDefaultConstraint(filteredElement, diagnostics, context); @@ -219,6 +220,16 @@ public class FiltersValidator extends EObjectValidator { * * @generated */ + public boolean validateFilterReference(FilterReference filterReference, DiagnosticChain diagnostics, Map<Object, Object> context) { + return validate_EveryDefaultConstraint(filterReference, diagnostics, context); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * + * @generated + */ public boolean validateOperatorKind(OperatorKind operatorKind, DiagnosticChain diagnostics, Map<Object, Object> context) { return true; } |