diff options
Diffstat (limited to 'tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org')
35 files changed, 0 insertions, 7715 deletions
diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/AnyEditPart.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/AnyEditPart.java deleted file mode 100644 index 3b8782ed94c..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/AnyEditPart.java +++ /dev/null @@ -1,26 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions; - - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Any Edit Part</b></em>'. - * <!-- end-user-doc --> - * - * - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#getAnyEditPart() - * @model - * @generated - */ -public interface AnyEditPart extends EditPartSpec { -} // AnyEditPart diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/CompositeEditPartSpec.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/CompositeEditPartSpec.java deleted file mode 100644 index 55ad86ab049..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/CompositeEditPartSpec.java +++ /dev/null @@ -1,100 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions; - -import org.eclipse.emf.common.util.EList; - -import org.eclipse.emf.ecore.EClass; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Composite Edit Part Spec</b></em>'. - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * </p> - * <ul> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.CompositeEditPartSpec#getOperator <em>Operator</em>}</li> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.CompositeEditPartSpec#getOperands <em>Operand</em>}</li> - * </ul> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#getCompositeEditPartSpec() - * @model - * @generated - */ -public interface CompositeEditPartSpec extends EditPartSpec { - /** - * Returns the value of the '<em><b>Operator</b></em>' attribute. - * The literals are from the enumeration {@link org.eclipse.papyrus.tests.framework.exceptions.OperatorKind}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Operator</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * - * @return the value of the '<em>Operator</em>' attribute. - * @see org.eclipse.papyrus.tests.framework.exceptions.OperatorKind - * @see #setOperator(OperatorKind) - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#getCompositeEditPartSpec_Operator() - * @model required="true" ordered="false" - * @generated - */ - OperatorKind getOperator(); - - /** - * Sets the value of the '{@link org.eclipse.papyrus.tests.framework.exceptions.CompositeEditPartSpec#getOperator <em>Operator</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param value - * the new value of the '<em>Operator</em>' attribute. - * @see org.eclipse.papyrus.tests.framework.exceptions.OperatorKind - * @see #getOperator() - * @generated - */ - void setOperator(OperatorKind value); - - /** - * Returns the value of the '<em><b>Operand</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec}. - * It is bidirectional and its opposite is '{@link org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec#getComposite <em>Composite</em>}'. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Operand</em>' containment reference list isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * - * @return the value of the '<em>Operand</em>' containment reference list. - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#getCompositeEditPartSpec_Operand() - * @see org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec#getComposite - * @model opposite="composite" containment="true" required="true" ordered="false" - * @generated - */ - EList<EditPartSpec> getOperands(); - - /** - * Creates a new {@link org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec} and appends it to the '<em><b>Operand</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param eClass - * The Ecore class of the {@link org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec} to create. - * @return The new {@link org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec}. - * @see #getOperands() - * @generated - */ - EditPartSpec createOperand(EClass eClass); - -} // CompositeEditPartSpec diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/EditPartRef.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/EditPartRef.java deleted file mode 100644 index cc0314a9f3a..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/EditPartRef.java +++ /dev/null @@ -1,62 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions; - -import org.eclipse.gmf.codegen.gmfgen.GenCommonBase; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Edit Part Ref</b></em>'. - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * </p> - * <ul> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.EditPartRef#getEditPart <em>Edit Part</em>}</li> - * </ul> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#getEditPartRef() - * @model - * @generated - */ -public interface EditPartRef extends EditPartSpec { - /** - * Returns the value of the '<em><b>Edit Part</b></em>' reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Edit Part</em>' reference isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * - * @return the value of the '<em>Edit Part</em>' reference. - * @see #setEditPart(GenCommonBase) - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#getEditPartRef_EditPart() - * @model required="true" ordered="false" - * @generated - */ - GenCommonBase getEditPart(); - - /** - * Sets the value of the '{@link org.eclipse.papyrus.tests.framework.exceptions.EditPartRef#getEditPart <em>Edit Part</em>}' reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param value - * the new value of the '<em>Edit Part</em>' reference. - * @see #getEditPart() - * @generated - */ - void setEditPart(GenCommonBase value); - -} // EditPartRef diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/EditPartSpec.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/EditPartSpec.java deleted file mode 100644 index 5a71cc2705f..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/EditPartSpec.java +++ /dev/null @@ -1,75 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.uml2.uml.InstanceSpecification; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Edit Part Spec</b></em>'. - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * </p> - * <ul> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec#getComposite <em>Composite</em>}</li> - * </ul> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#getEditPartSpec() - * @model abstract="true" - * @generated - */ -public interface EditPartSpec extends EObject { - /** - * Returns the value of the '<em><b>Composite</b></em>' container reference. - * It is bidirectional and its opposite is '{@link org.eclipse.papyrus.tests.framework.exceptions.CompositeEditPartSpec#getOperands <em>Operand</em>}'. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Composite</em>' container reference isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * - * @return the value of the '<em>Composite</em>' container reference. - * @see #setComposite(CompositeEditPartSpec) - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#getEditPartSpec_Composite() - * @see org.eclipse.papyrus.tests.framework.exceptions.CompositeEditPartSpec#getOperands - * @model opposite="operand" transient="false" ordered="false" - * @generated - */ - CompositeEditPartSpec getComposite(); - - /** - * Sets the value of the '{@link org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec#getComposite <em>Composite</em>}' container reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param value - * the new value of the '<em>Composite</em>' container reference. - * @see #getComposite() - * @generated - */ - void setComposite(CompositeEditPartSpec value); - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @model dataType="org.eclipse.uml2.types.Boolean" required="true" ordered="false" editPartRequired="true" editPartOrdered="false" - * @generated - */ - boolean matches(InstanceSpecification editPart); - -} // EditPartSpec diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/ExceptionsFactory.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/ExceptionsFactory.java deleted file mode 100644 index 8a7845f720c..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/ExceptionsFactory.java +++ /dev/null @@ -1,105 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions; - -import org.eclipse.emf.ecore.EFactory; - -/** - * <!-- begin-user-doc --> - * The <b>Factory</b> for the model. - * It provides a create method for each non-abstract class of the model. - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage - * @generated - */ -public interface ExceptionsFactory extends EFactory { - /** - * The singleton instance of the factory. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - ExceptionsFactory eINSTANCE = org.eclipse.papyrus.tests.framework.exceptions.impl.ExceptionsFactoryImpl.init(); - - /** - * Returns a new object of class '<em>Forbidden Edit Part Permutation</em>'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return a new object of class '<em>Forbidden Edit Part Permutation</em>'. - * @generated - */ - ForbiddenEditPartPermutation createForbiddenEditPartPermutation(); - - /** - * Returns a new object of class '<em>Test Exceptions</em>'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return a new object of class '<em>Test Exceptions</em>'. - * @generated - */ - TestExceptions createTestExceptions(); - - /** - * Returns a new object of class '<em>Composite Edit Part Spec</em>'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return a new object of class '<em>Composite Edit Part Spec</em>'. - * @generated - */ - CompositeEditPartSpec createCompositeEditPartSpec(); - - /** - * Returns a new object of class '<em>Edit Part Ref</em>'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return a new object of class '<em>Edit Part Ref</em>'. - * @generated - */ - EditPartRef createEditPartRef(); - - /** - * Returns a new object of class '<em>Any Edit Part</em>'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return a new object of class '<em>Any Edit Part</em>'. - * @generated - */ - AnyEditPart createAnyEditPart(); - - /** - * Returns a new object of class '<em>Forbidden Edit Part</em>'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return a new object of class '<em>Forbidden Edit Part</em>'. - * @generated - */ - ForbiddenEditPart createForbiddenEditPart(); - - /** - * Returns the package supported by this factory. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the package supported by this factory. - * @generated - */ - ExceptionsPackage getExceptionsPackage(); - -} // ExceptionsFactory diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/ExceptionsPackage.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/ExceptionsPackage.java deleted file mode 100644 index 2fe7e5daaaa..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/ExceptionsPackage.java +++ /dev/null @@ -1,1269 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions; - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EEnum; -import org.eclipse.emf.ecore.EOperation; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; - -/** - * <!-- begin-user-doc --> - * The <b>Package</b> for the model. - * It contains accessors for the meta objects to represent - * <ul> - * <li>each class,</li> - * <li>each feature of each class,</li> - * <li>each operation of each class,</li> - * <li>each enum,</li> - * <li>and each data type</li> - * </ul> - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsFactory - * @model kind="package" - * annotation="http://www.eclipse.org/emf/2002/Ecore validationDelegates='http://www.eclipse.org/emf/2002/Ecore/OCL'" - * @generated - */ -public interface ExceptionsPackage extends EPackage { - /** - * The package name. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - String eNAME = "exceptions"; - - /** - * The package namespace URI. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - String eNS_URI = "http://www.eclipse.org/papyrus/2015/testframework/exceptions"; - - /** - * The package namespace name. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - String eNS_PREFIX = "exceptions"; - - /** - * The singleton instance of the package. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - ExceptionsPackage eINSTANCE = org.eclipse.papyrus.tests.framework.exceptions.impl.ExceptionsPackageImpl.init(); - - /** - * The meta object id for the '{@link org.eclipse.papyrus.tests.framework.exceptions.impl.TestConstraintImpl <em>Test Constraint</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.TestConstraintImpl - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.ExceptionsPackageImpl#getTestConstraint() - * @generated - */ - int TEST_CONSTRAINT = 1; - - /** - * The feature id for the '<em><b>Container</b></em>' container reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int TEST_CONSTRAINT__CONTAINER = 0; - - /** - * The feature id for the '<em><b>Omit On Failure</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int TEST_CONSTRAINT__OMIT_ON_FAILURE = 1; - - /** - * The number of structural features of the '<em>Test Constraint</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int TEST_CONSTRAINT_FEATURE_COUNT = 2; - - /** - * The operation id for the '<em>Validate</em>' operation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int TEST_CONSTRAINT___VALIDATE__ELIST_CLASS_DIAGNOSTICCHAIN = 0; - - /** - * The number of operations of the '<em>Test Constraint</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int TEST_CONSTRAINT_OPERATION_COUNT = 1; - - /** - * The meta object id for the '{@link org.eclipse.papyrus.tests.framework.exceptions.impl.ForbiddenEditPartPermutationImpl <em>Forbidden Edit Part Permutation</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.ForbiddenEditPartPermutationImpl - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.ExceptionsPackageImpl#getForbiddenEditPartPermutation() - * @generated - */ - int FORBIDDEN_EDIT_PART_PERMUTATION = 0; - - /** - * The feature id for the '<em><b>Container</b></em>' container reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int FORBIDDEN_EDIT_PART_PERMUTATION__CONTAINER = TEST_CONSTRAINT__CONTAINER; - - /** - * The feature id for the '<em><b>Omit On Failure</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int FORBIDDEN_EDIT_PART_PERMUTATION__OMIT_ON_FAILURE = TEST_CONSTRAINT__OMIT_ON_FAILURE; - - /** - * The feature id for the '<em><b>Reason Kind</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int FORBIDDEN_EDIT_PART_PERMUTATION__REASON_KIND = TEST_CONSTRAINT_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Reason</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int FORBIDDEN_EDIT_PART_PERMUTATION__REASON = TEST_CONSTRAINT_FEATURE_COUNT + 1; - - /** - * The feature id for the '<em><b>Test Class</b></em>' reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int FORBIDDEN_EDIT_PART_PERMUTATION__TEST_CLASS = TEST_CONSTRAINT_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Edit Part</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int FORBIDDEN_EDIT_PART_PERMUTATION__EDIT_PART = TEST_CONSTRAINT_FEATURE_COUNT + 3; - - /** - * The number of structural features of the '<em>Forbidden Edit Part Permutation</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int FORBIDDEN_EDIT_PART_PERMUTATION_FEATURE_COUNT = TEST_CONSTRAINT_FEATURE_COUNT + 4; - - /** - * The operation id for the '<em>Validate</em>' operation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int FORBIDDEN_EDIT_PART_PERMUTATION___VALIDATE__ELIST_CLASS_DIAGNOSTICCHAIN = TEST_CONSTRAINT___VALIDATE__ELIST_CLASS_DIAGNOSTICCHAIN; - - /** - * The operation id for the '<em>Test classes</em>' operation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int FORBIDDEN_EDIT_PART_PERMUTATION___TEST_CLASSES__DIAGNOSTICCHAIN_MAP = TEST_CONSTRAINT_OPERATION_COUNT + 0; - - /** - * The number of operations of the '<em>Forbidden Edit Part Permutation</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int FORBIDDEN_EDIT_PART_PERMUTATION_OPERATION_COUNT = TEST_CONSTRAINT_OPERATION_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.papyrus.tests.framework.exceptions.impl.TestExceptionsImpl <em>Test Exceptions</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.TestExceptionsImpl - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.ExceptionsPackageImpl#getTestExceptions() - * @generated - */ - int TEST_EXCEPTIONS = 2; - - /** - * The feature id for the '<em><b>Constraint</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int TEST_EXCEPTIONS__CONSTRAINT = 0; - - /** - * The number of structural features of the '<em>Test Exceptions</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int TEST_EXCEPTIONS_FEATURE_COUNT = 1; - - /** - * The operation id for the '<em>Validate</em>' operation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int TEST_EXCEPTIONS___VALIDATE__ELIST_CLASS_DIAGNOSTICCHAIN = 0; - - /** - * The number of operations of the '<em>Test Exceptions</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int TEST_EXCEPTIONS_OPERATION_COUNT = 1; - - /** - * The meta object id for the '{@link org.eclipse.papyrus.tests.framework.exceptions.impl.EditPartSpecImpl <em>Edit Part Spec</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.EditPartSpecImpl - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.ExceptionsPackageImpl#getEditPartSpec() - * @generated - */ - int EDIT_PART_SPEC = 3; - - /** - * The feature id for the '<em><b>Composite</b></em>' container reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int EDIT_PART_SPEC__COMPOSITE = 0; - - /** - * The number of structural features of the '<em>Edit Part Spec</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int EDIT_PART_SPEC_FEATURE_COUNT = 1; - - /** - * The operation id for the '<em>Matches</em>' operation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int EDIT_PART_SPEC___MATCHES__INSTANCESPECIFICATION = 0; - - /** - * The number of operations of the '<em>Edit Part Spec</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int EDIT_PART_SPEC_OPERATION_COUNT = 1; - - /** - * The meta object id for the '{@link org.eclipse.papyrus.tests.framework.exceptions.impl.CompositeEditPartSpecImpl <em>Composite Edit Part Spec</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.CompositeEditPartSpecImpl - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.ExceptionsPackageImpl#getCompositeEditPartSpec() - * @generated - */ - int COMPOSITE_EDIT_PART_SPEC = 4; - - /** - * The feature id for the '<em><b>Composite</b></em>' container reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int COMPOSITE_EDIT_PART_SPEC__COMPOSITE = EDIT_PART_SPEC__COMPOSITE; - - /** - * The feature id for the '<em><b>Operator</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int COMPOSITE_EDIT_PART_SPEC__OPERATOR = EDIT_PART_SPEC_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Operand</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int COMPOSITE_EDIT_PART_SPEC__OPERAND = EDIT_PART_SPEC_FEATURE_COUNT + 1; - - /** - * The number of structural features of the '<em>Composite Edit Part Spec</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int COMPOSITE_EDIT_PART_SPEC_FEATURE_COUNT = EDIT_PART_SPEC_FEATURE_COUNT + 2; - - /** - * The operation id for the '<em>Matches</em>' operation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int COMPOSITE_EDIT_PART_SPEC___MATCHES__INSTANCESPECIFICATION = EDIT_PART_SPEC___MATCHES__INSTANCESPECIFICATION; - - /** - * The number of operations of the '<em>Composite Edit Part Spec</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int COMPOSITE_EDIT_PART_SPEC_OPERATION_COUNT = EDIT_PART_SPEC_OPERATION_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.papyrus.tests.framework.exceptions.impl.EditPartRefImpl <em>Edit Part Ref</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.EditPartRefImpl - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.ExceptionsPackageImpl#getEditPartRef() - * @generated - */ - int EDIT_PART_REF = 5; - - /** - * The feature id for the '<em><b>Composite</b></em>' container reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int EDIT_PART_REF__COMPOSITE = EDIT_PART_SPEC__COMPOSITE; - - /** - * The feature id for the '<em><b>Edit Part</b></em>' reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int EDIT_PART_REF__EDIT_PART = EDIT_PART_SPEC_FEATURE_COUNT + 0; - - /** - * The number of structural features of the '<em>Edit Part Ref</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int EDIT_PART_REF_FEATURE_COUNT = EDIT_PART_SPEC_FEATURE_COUNT + 1; - - /** - * The operation id for the '<em>Matches</em>' operation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int EDIT_PART_REF___MATCHES__INSTANCESPECIFICATION = EDIT_PART_SPEC___MATCHES__INSTANCESPECIFICATION; - - /** - * The number of operations of the '<em>Edit Part Ref</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int EDIT_PART_REF_OPERATION_COUNT = EDIT_PART_SPEC_OPERATION_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.papyrus.tests.framework.exceptions.impl.AnyEditPartImpl <em>Any Edit Part</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.AnyEditPartImpl - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.ExceptionsPackageImpl#getAnyEditPart() - * @generated - */ - int ANY_EDIT_PART = 6; - - /** - * The feature id for the '<em><b>Composite</b></em>' container reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int ANY_EDIT_PART__COMPOSITE = EDIT_PART_SPEC__COMPOSITE; - - /** - * The number of structural features of the '<em>Any Edit Part</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int ANY_EDIT_PART_FEATURE_COUNT = EDIT_PART_SPEC_FEATURE_COUNT + 0; - - /** - * The operation id for the '<em>Matches</em>' operation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int ANY_EDIT_PART___MATCHES__INSTANCESPECIFICATION = EDIT_PART_SPEC___MATCHES__INSTANCESPECIFICATION; - - /** - * The number of operations of the '<em>Any Edit Part</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int ANY_EDIT_PART_OPERATION_COUNT = EDIT_PART_SPEC_OPERATION_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.papyrus.tests.framework.exceptions.impl.ForbiddenEditPartImpl <em>Forbidden Edit Part</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.ForbiddenEditPartImpl - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.ExceptionsPackageImpl#getForbiddenEditPart() - * @generated - */ - int FORBIDDEN_EDIT_PART = 7; - - /** - * The feature id for the '<em><b>Container</b></em>' container reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int FORBIDDEN_EDIT_PART__CONTAINER = TEST_CONSTRAINT__CONTAINER; - - /** - * The feature id for the '<em><b>Omit On Failure</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int FORBIDDEN_EDIT_PART__OMIT_ON_FAILURE = TEST_CONSTRAINT__OMIT_ON_FAILURE; - - /** - * The feature id for the '<em><b>Edit Part</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int FORBIDDEN_EDIT_PART__EDIT_PART = TEST_CONSTRAINT_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Reason</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int FORBIDDEN_EDIT_PART__REASON = TEST_CONSTRAINT_FEATURE_COUNT + 1; - - /** - * The feature id for the '<em><b>Reason Kind</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int FORBIDDEN_EDIT_PART__REASON_KIND = TEST_CONSTRAINT_FEATURE_COUNT + 2; - - /** - * The number of structural features of the '<em>Forbidden Edit Part</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int FORBIDDEN_EDIT_PART_FEATURE_COUNT = TEST_CONSTRAINT_FEATURE_COUNT + 3; - - /** - * The operation id for the '<em>Validate</em>' operation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int FORBIDDEN_EDIT_PART___VALIDATE__ELIST_CLASS_DIAGNOSTICCHAIN = TEST_CONSTRAINT___VALIDATE__ELIST_CLASS_DIAGNOSTICCHAIN; - - /** - * The number of operations of the '<em>Forbidden Edit Part</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int FORBIDDEN_EDIT_PART_OPERATION_COUNT = TEST_CONSTRAINT_OPERATION_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenReasonKind <em>Forbidden Reason Kind</em>}' enum. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.ForbiddenReasonKind - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.ExceptionsPackageImpl#getForbiddenReasonKind() - * @generated - */ - int FORBIDDEN_REASON_KIND = 8; - - - /** - * The meta object id for the '{@link org.eclipse.papyrus.tests.framework.exceptions.OperatorKind <em>Operator Kind</em>}' enum. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.OperatorKind - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.ExceptionsPackageImpl#getOperatorKind() - * @generated - */ - int OPERATOR_KIND = 9; - - - /** - * Returns the meta object for class '{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPartPermutation <em>Forbidden Edit Part Permutation</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for class '<em>Forbidden Edit Part Permutation</em>'. - * @see org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPartPermutation - * @generated - */ - EClass getForbiddenEditPartPermutation(); - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPartPermutation#getEditParts <em>Edit Part</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for the containment reference list '<em>Edit Part</em>'. - * @see org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPartPermutation#getEditParts() - * @see #getForbiddenEditPartPermutation() - * @generated - */ - EReference getForbiddenEditPartPermutation_EditPart(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPartPermutation#getReasonKind <em>Reason Kind</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for the attribute '<em>Reason Kind</em>'. - * @see org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPartPermutation#getReasonKind() - * @see #getForbiddenEditPartPermutation() - * @generated - */ - EAttribute getForbiddenEditPartPermutation_ReasonKind(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPartPermutation#getReason <em>Reason</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for the attribute '<em>Reason</em>'. - * @see org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPartPermutation#getReason() - * @see #getForbiddenEditPartPermutation() - * @generated - */ - EAttribute getForbiddenEditPartPermutation_Reason(); - - /** - * Returns the meta object for the reference list '{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPartPermutation#getTestClasses <em>Test Class</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for the reference list '<em>Test Class</em>'. - * @see org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPartPermutation#getTestClasses() - * @see #getForbiddenEditPartPermutation() - * @generated - */ - EReference getForbiddenEditPartPermutation_TestClass(); - - /** - * Returns the meta object for the '{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPartPermutation#test_classes(org.eclipse.emf.common.util.DiagnosticChain, java.util.Map) <em>Test classes</em>}' operation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for the '<em>Test classes</em>' operation. - * @see org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPartPermutation#test_classes(org.eclipse.emf.common.util.DiagnosticChain, java.util.Map) - * @generated - */ - EOperation getForbiddenEditPartPermutation__Test_classes__DiagnosticChain_Map(); - - /** - * Returns the meta object for class '{@link org.eclipse.papyrus.tests.framework.exceptions.TestConstraint <em>Test Constraint</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for class '<em>Test Constraint</em>'. - * @see org.eclipse.papyrus.tests.framework.exceptions.TestConstraint - * @generated - */ - EClass getTestConstraint(); - - /** - * Returns the meta object for the container reference '{@link org.eclipse.papyrus.tests.framework.exceptions.TestConstraint#getContainer <em>Container</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for the container reference '<em>Container</em>'. - * @see org.eclipse.papyrus.tests.framework.exceptions.TestConstraint#getContainer() - * @see #getTestConstraint() - * @generated - */ - EReference getTestConstraint_Container(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.papyrus.tests.framework.exceptions.TestConstraint#isOmitOnFailure <em>Omit On Failure</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for the attribute '<em>Omit On Failure</em>'. - * @see org.eclipse.papyrus.tests.framework.exceptions.TestConstraint#isOmitOnFailure() - * @see #getTestConstraint() - * @generated - */ - EAttribute getTestConstraint_OmitOnFailure(); - - /** - * Returns the meta object for the '{@link org.eclipse.papyrus.tests.framework.exceptions.TestConstraint#validate(org.eclipse.emf.common.util.EList, org.eclipse.uml2.uml.Class, org.eclipse.emf.common.util.DiagnosticChain) <em>Validate</em>}' operation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for the '<em>Validate</em>' operation. - * @see org.eclipse.papyrus.tests.framework.exceptions.TestConstraint#validate(org.eclipse.emf.common.util.EList, org.eclipse.uml2.uml.Class, org.eclipse.emf.common.util.DiagnosticChain) - * @generated - */ - EOperation getTestConstraint__Validate__EList_Class_DiagnosticChain(); - - /** - * Returns the meta object for class '{@link org.eclipse.papyrus.tests.framework.exceptions.TestExceptions <em>Test Exceptions</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for class '<em>Test Exceptions</em>'. - * @see org.eclipse.papyrus.tests.framework.exceptions.TestExceptions - * @generated - */ - EClass getTestExceptions(); - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.papyrus.tests.framework.exceptions.TestExceptions#getConstraints <em>Constraint</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for the containment reference list '<em>Constraint</em>'. - * @see org.eclipse.papyrus.tests.framework.exceptions.TestExceptions#getConstraints() - * @see #getTestExceptions() - * @generated - */ - EReference getTestExceptions_Constraint(); - - /** - * Returns the meta object for the '{@link org.eclipse.papyrus.tests.framework.exceptions.TestExceptions#validate(org.eclipse.emf.common.util.EList, org.eclipse.uml2.uml.Class, org.eclipse.emf.common.util.DiagnosticChain) <em>Validate</em>}' operation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for the '<em>Validate</em>' operation. - * @see org.eclipse.papyrus.tests.framework.exceptions.TestExceptions#validate(org.eclipse.emf.common.util.EList, org.eclipse.uml2.uml.Class, org.eclipse.emf.common.util.DiagnosticChain) - * @generated - */ - EOperation getTestExceptions__Validate__EList_Class_DiagnosticChain(); - - /** - * Returns the meta object for class '{@link org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec <em>Edit Part Spec</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for class '<em>Edit Part Spec</em>'. - * @see org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec - * @generated - */ - EClass getEditPartSpec(); - - /** - * Returns the meta object for the container reference '{@link org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec#getComposite <em>Composite</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for the container reference '<em>Composite</em>'. - * @see org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec#getComposite() - * @see #getEditPartSpec() - * @generated - */ - EReference getEditPartSpec_Composite(); - - /** - * Returns the meta object for the '{@link org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec#matches(org.eclipse.uml2.uml.InstanceSpecification) <em>Matches</em>}' operation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for the '<em>Matches</em>' operation. - * @see org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec#matches(org.eclipse.uml2.uml.InstanceSpecification) - * @generated - */ - EOperation getEditPartSpec__Matches__InstanceSpecification(); - - /** - * Returns the meta object for class '{@link org.eclipse.papyrus.tests.framework.exceptions.CompositeEditPartSpec <em>Composite Edit Part Spec</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for class '<em>Composite Edit Part Spec</em>'. - * @see org.eclipse.papyrus.tests.framework.exceptions.CompositeEditPartSpec - * @generated - */ - EClass getCompositeEditPartSpec(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.papyrus.tests.framework.exceptions.CompositeEditPartSpec#getOperator <em>Operator</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for the attribute '<em>Operator</em>'. - * @see org.eclipse.papyrus.tests.framework.exceptions.CompositeEditPartSpec#getOperator() - * @see #getCompositeEditPartSpec() - * @generated - */ - EAttribute getCompositeEditPartSpec_Operator(); - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.papyrus.tests.framework.exceptions.CompositeEditPartSpec#getOperands <em>Operand</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for the containment reference list '<em>Operand</em>'. - * @see org.eclipse.papyrus.tests.framework.exceptions.CompositeEditPartSpec#getOperands() - * @see #getCompositeEditPartSpec() - * @generated - */ - EReference getCompositeEditPartSpec_Operand(); - - /** - * Returns the meta object for class '{@link org.eclipse.papyrus.tests.framework.exceptions.EditPartRef <em>Edit Part Ref</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for class '<em>Edit Part Ref</em>'. - * @see org.eclipse.papyrus.tests.framework.exceptions.EditPartRef - * @generated - */ - EClass getEditPartRef(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.papyrus.tests.framework.exceptions.EditPartRef#getEditPart <em>Edit Part</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for the reference '<em>Edit Part</em>'. - * @see org.eclipse.papyrus.tests.framework.exceptions.EditPartRef#getEditPart() - * @see #getEditPartRef() - * @generated - */ - EReference getEditPartRef_EditPart(); - - /** - * Returns the meta object for class '{@link org.eclipse.papyrus.tests.framework.exceptions.AnyEditPart <em>Any Edit Part</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for class '<em>Any Edit Part</em>'. - * @see org.eclipse.papyrus.tests.framework.exceptions.AnyEditPart - * @generated - */ - EClass getAnyEditPart(); - - /** - * Returns the meta object for class '{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPart <em>Forbidden Edit Part</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for class '<em>Forbidden Edit Part</em>'. - * @see org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPart - * @generated - */ - EClass getForbiddenEditPart(); - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPart#getEditPart <em>Edit Part</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for the containment reference '<em>Edit Part</em>'. - * @see org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPart#getEditPart() - * @see #getForbiddenEditPart() - * @generated - */ - EReference getForbiddenEditPart_EditPart(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPart#getReason <em>Reason</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for the attribute '<em>Reason</em>'. - * @see org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPart#getReason() - * @see #getForbiddenEditPart() - * @generated - */ - EAttribute getForbiddenEditPart_Reason(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPart#getReasonKind <em>Reason Kind</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for the attribute '<em>Reason Kind</em>'. - * @see org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPart#getReasonKind() - * @see #getForbiddenEditPart() - * @generated - */ - EAttribute getForbiddenEditPart_ReasonKind(); - - /** - * Returns the meta object for enum '{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenReasonKind <em>Forbidden Reason Kind</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for enum '<em>Forbidden Reason Kind</em>'. - * @see org.eclipse.papyrus.tests.framework.exceptions.ForbiddenReasonKind - * @generated - */ - EEnum getForbiddenReasonKind(); - - /** - * Returns the meta object for enum '{@link org.eclipse.papyrus.tests.framework.exceptions.OperatorKind <em>Operator Kind</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the meta object for enum '<em>Operator Kind</em>'. - * @see org.eclipse.papyrus.tests.framework.exceptions.OperatorKind - * @generated - */ - EEnum getOperatorKind(); - - /** - * Returns the factory that creates the instances of the model. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the factory that creates the instances of the model. - * @generated - */ - ExceptionsFactory getExceptionsFactory(); - - /** - * <!-- begin-user-doc --> - * Defines literals for the meta objects that represent - * <ul> - * <li>each class,</li> - * <li>each feature of each class,</li> - * <li>each operation of each class,</li> - * <li>each enum,</li> - * <li>and each data type</li> - * </ul> - * <!-- end-user-doc --> - * - * @generated - */ - interface Literals { - /** - * The meta object literal for the '{@link org.eclipse.papyrus.tests.framework.exceptions.impl.ForbiddenEditPartPermutationImpl <em>Forbidden Edit Part Permutation</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.ForbiddenEditPartPermutationImpl - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.ExceptionsPackageImpl#getForbiddenEditPartPermutation() - * @generated - */ - EClass FORBIDDEN_EDIT_PART_PERMUTATION = eINSTANCE.getForbiddenEditPartPermutation(); - - /** - * The meta object literal for the '<em><b>Edit Part</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - EReference FORBIDDEN_EDIT_PART_PERMUTATION__EDIT_PART = eINSTANCE.getForbiddenEditPartPermutation_EditPart(); - - /** - * The meta object literal for the '<em><b>Reason Kind</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - EAttribute FORBIDDEN_EDIT_PART_PERMUTATION__REASON_KIND = eINSTANCE.getForbiddenEditPartPermutation_ReasonKind(); - - /** - * The meta object literal for the '<em><b>Reason</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - EAttribute FORBIDDEN_EDIT_PART_PERMUTATION__REASON = eINSTANCE.getForbiddenEditPartPermutation_Reason(); - - /** - * The meta object literal for the '<em><b>Test Class</b></em>' reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - EReference FORBIDDEN_EDIT_PART_PERMUTATION__TEST_CLASS = eINSTANCE.getForbiddenEditPartPermutation_TestClass(); - - /** - * The meta object literal for the '<em><b>Test classes</b></em>' operation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - EOperation FORBIDDEN_EDIT_PART_PERMUTATION___TEST_CLASSES__DIAGNOSTICCHAIN_MAP = eINSTANCE.getForbiddenEditPartPermutation__Test_classes__DiagnosticChain_Map(); - - /** - * The meta object literal for the '{@link org.eclipse.papyrus.tests.framework.exceptions.impl.TestConstraintImpl <em>Test Constraint</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.TestConstraintImpl - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.ExceptionsPackageImpl#getTestConstraint() - * @generated - */ - EClass TEST_CONSTRAINT = eINSTANCE.getTestConstraint(); - - /** - * The meta object literal for the '<em><b>Container</b></em>' container reference feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - EReference TEST_CONSTRAINT__CONTAINER = eINSTANCE.getTestConstraint_Container(); - - /** - * The meta object literal for the '<em><b>Omit On Failure</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - EAttribute TEST_CONSTRAINT__OMIT_ON_FAILURE = eINSTANCE.getTestConstraint_OmitOnFailure(); - - /** - * The meta object literal for the '<em><b>Validate</b></em>' operation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - EOperation TEST_CONSTRAINT___VALIDATE__ELIST_CLASS_DIAGNOSTICCHAIN = eINSTANCE.getTestConstraint__Validate__EList_Class_DiagnosticChain(); - - /** - * The meta object literal for the '{@link org.eclipse.papyrus.tests.framework.exceptions.impl.TestExceptionsImpl <em>Test Exceptions</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.TestExceptionsImpl - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.ExceptionsPackageImpl#getTestExceptions() - * @generated - */ - EClass TEST_EXCEPTIONS = eINSTANCE.getTestExceptions(); - - /** - * The meta object literal for the '<em><b>Constraint</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - EReference TEST_EXCEPTIONS__CONSTRAINT = eINSTANCE.getTestExceptions_Constraint(); - - /** - * The meta object literal for the '<em><b>Validate</b></em>' operation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - EOperation TEST_EXCEPTIONS___VALIDATE__ELIST_CLASS_DIAGNOSTICCHAIN = eINSTANCE.getTestExceptions__Validate__EList_Class_DiagnosticChain(); - - /** - * The meta object literal for the '{@link org.eclipse.papyrus.tests.framework.exceptions.impl.EditPartSpecImpl <em>Edit Part Spec</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.EditPartSpecImpl - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.ExceptionsPackageImpl#getEditPartSpec() - * @generated - */ - EClass EDIT_PART_SPEC = eINSTANCE.getEditPartSpec(); - - /** - * The meta object literal for the '<em><b>Composite</b></em>' container reference feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - EReference EDIT_PART_SPEC__COMPOSITE = eINSTANCE.getEditPartSpec_Composite(); - - /** - * The meta object literal for the '<em><b>Matches</b></em>' operation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - EOperation EDIT_PART_SPEC___MATCHES__INSTANCESPECIFICATION = eINSTANCE.getEditPartSpec__Matches__InstanceSpecification(); - - /** - * The meta object literal for the '{@link org.eclipse.papyrus.tests.framework.exceptions.impl.CompositeEditPartSpecImpl <em>Composite Edit Part Spec</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.CompositeEditPartSpecImpl - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.ExceptionsPackageImpl#getCompositeEditPartSpec() - * @generated - */ - EClass COMPOSITE_EDIT_PART_SPEC = eINSTANCE.getCompositeEditPartSpec(); - - /** - * The meta object literal for the '<em><b>Operator</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - EAttribute COMPOSITE_EDIT_PART_SPEC__OPERATOR = eINSTANCE.getCompositeEditPartSpec_Operator(); - - /** - * The meta object literal for the '<em><b>Operand</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - EReference COMPOSITE_EDIT_PART_SPEC__OPERAND = eINSTANCE.getCompositeEditPartSpec_Operand(); - - /** - * The meta object literal for the '{@link org.eclipse.papyrus.tests.framework.exceptions.impl.EditPartRefImpl <em>Edit Part Ref</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.EditPartRefImpl - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.ExceptionsPackageImpl#getEditPartRef() - * @generated - */ - EClass EDIT_PART_REF = eINSTANCE.getEditPartRef(); - - /** - * The meta object literal for the '<em><b>Edit Part</b></em>' reference feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - EReference EDIT_PART_REF__EDIT_PART = eINSTANCE.getEditPartRef_EditPart(); - - /** - * The meta object literal for the '{@link org.eclipse.papyrus.tests.framework.exceptions.impl.AnyEditPartImpl <em>Any Edit Part</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.AnyEditPartImpl - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.ExceptionsPackageImpl#getAnyEditPart() - * @generated - */ - EClass ANY_EDIT_PART = eINSTANCE.getAnyEditPart(); - - /** - * The meta object literal for the '{@link org.eclipse.papyrus.tests.framework.exceptions.impl.ForbiddenEditPartImpl <em>Forbidden Edit Part</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.ForbiddenEditPartImpl - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.ExceptionsPackageImpl#getForbiddenEditPart() - * @generated - */ - EClass FORBIDDEN_EDIT_PART = eINSTANCE.getForbiddenEditPart(); - - /** - * The meta object literal for the '<em><b>Edit Part</b></em>' containment reference feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - EReference FORBIDDEN_EDIT_PART__EDIT_PART = eINSTANCE.getForbiddenEditPart_EditPart(); - - /** - * The meta object literal for the '<em><b>Reason</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - EAttribute FORBIDDEN_EDIT_PART__REASON = eINSTANCE.getForbiddenEditPart_Reason(); - - /** - * The meta object literal for the '<em><b>Reason Kind</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - EAttribute FORBIDDEN_EDIT_PART__REASON_KIND = eINSTANCE.getForbiddenEditPart_ReasonKind(); - - /** - * The meta object literal for the '{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenReasonKind <em>Forbidden Reason Kind</em>}' enum. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.ForbiddenReasonKind - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.ExceptionsPackageImpl#getForbiddenReasonKind() - * @generated - */ - EEnum FORBIDDEN_REASON_KIND = eINSTANCE.getForbiddenReasonKind(); - - /** - * The meta object literal for the '{@link org.eclipse.papyrus.tests.framework.exceptions.OperatorKind <em>Operator Kind</em>}' enum. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.OperatorKind - * @see org.eclipse.papyrus.tests.framework.exceptions.impl.ExceptionsPackageImpl#getOperatorKind() - * @generated - */ - EEnum OPERATOR_KIND = eINSTANCE.getOperatorKind(); - - } - -} // ExceptionsPackage diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/ForbiddenEditPart.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/ForbiddenEditPart.java deleted file mode 100644 index d402182dfa7..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/ForbiddenEditPart.java +++ /dev/null @@ -1,139 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions; - -import org.eclipse.emf.ecore.EClass; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Forbidden Edit Part</b></em>'. - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * </p> - * <ul> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPart#getEditPart <em>Edit Part</em>}</li> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPart#getReason <em>Reason</em>}</li> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPart#getReasonKind <em>Reason Kind</em>}</li> - * </ul> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#getForbiddenEditPart() - * @model - * @generated - */ -public interface ForbiddenEditPart extends TestConstraint { - /** - * Returns the value of the '<em><b>Edit Part</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Edit Part</em>' containment reference isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * - * @return the value of the '<em>Edit Part</em>' containment reference. - * @see #setEditPart(EditPartSpec) - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#getForbiddenEditPart_EditPart() - * @model containment="true" required="true" ordered="false" - * @generated - */ - EditPartSpec getEditPart(); - - /** - * Sets the value of the '{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPart#getEditPart <em>Edit Part</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param value - * the new value of the '<em>Edit Part</em>' containment reference. - * @see #getEditPart() - * @generated - */ - void setEditPart(EditPartSpec value); - - /** - * Creates a new {@link org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec} and sets the '<em><b>Edit Part</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param eClass - * The Ecore class of the {@link org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec} to create. - * @return The new {@link org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec}. - * @see #getEditPart() - * @generated - */ - EditPartSpec createEditPart(EClass eClass); - - /** - * Returns the value of the '<em><b>Reason</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Reason</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * - * @return the value of the '<em>Reason</em>' attribute. - * @see #setReason(String) - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#getForbiddenEditPart_Reason() - * @model dataType="org.eclipse.uml2.types.String" ordered="false" - * @generated - */ - String getReason(); - - /** - * Sets the value of the '{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPart#getReason <em>Reason</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param value - * the new value of the '<em>Reason</em>' attribute. - * @see #getReason() - * @generated - */ - void setReason(String value); - - /** - * Returns the value of the '<em><b>Reason Kind</b></em>' attribute. - * The default value is <code>"invalid"</code>. - * The literals are from the enumeration {@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenReasonKind}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Reason Kind</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * - * @return the value of the '<em>Reason Kind</em>' attribute. - * @see org.eclipse.papyrus.tests.framework.exceptions.ForbiddenReasonKind - * @see #setReasonKind(ForbiddenReasonKind) - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#getForbiddenEditPart_ReasonKind() - * @model default="invalid" required="true" ordered="false" - * @generated - */ - ForbiddenReasonKind getReasonKind(); - - /** - * Sets the value of the '{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPart#getReasonKind <em>Reason Kind</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param value - * the new value of the '<em>Reason Kind</em>' attribute. - * @see org.eclipse.papyrus.tests.framework.exceptions.ForbiddenReasonKind - * @see #getReasonKind() - * @generated - */ - void setReasonKind(ForbiddenReasonKind value); - -} // ForbiddenEditPart diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/ForbiddenEditPartPermutation.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/ForbiddenEditPartPermutation.java deleted file mode 100644 index e44ca80ee94..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/ForbiddenEditPartPermutation.java +++ /dev/null @@ -1,196 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions; - -import java.util.Map; - -import org.eclipse.emf.common.util.DiagnosticChain; -import org.eclipse.emf.common.util.EList; - -import org.eclipse.emf.ecore.EClass; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Forbidden Edit Part Permutation</b></em>'. - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * </p> - * <ul> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPartPermutation#getReasonKind <em>Reason Kind</em>}</li> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPartPermutation#getReason <em>Reason</em>}</li> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPartPermutation#getTestClasses <em>Test Class</em>}</li> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPartPermutation#getEditParts <em>Edit Part</em>}</li> - * </ul> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#getForbiddenEditPartPermutation() - * @model - * @generated - */ -public interface ForbiddenEditPartPermutation extends TestConstraint { - /** - * Returns the value of the '<em><b>Edit Part</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Edit Part</em>' reference list isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * - * @return the value of the '<em>Edit Part</em>' containment reference list. - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#getForbiddenEditPartPermutation_EditPart() - * @model containment="true" required="true" ordered="false" - * @generated - */ - EList<EditPartSpec> getEditParts(); - - /** - * Creates a new {@link org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec} and appends it to the '<em><b>Edit Part</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param eClass - * The Ecore class of the {@link org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec} to create. - * @return The new {@link org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec}. - * @see #getEditParts() - * @generated - */ - EditPartSpec createEditPart(EClass eClass); - - /** - * Returns the value of the '<em><b>Reason Kind</b></em>' attribute. - * The default value is <code>"invalid"</code>. - * The literals are from the enumeration {@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenReasonKind}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Reason Kind</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * - * @return the value of the '<em>Reason Kind</em>' attribute. - * @see org.eclipse.papyrus.tests.framework.exceptions.ForbiddenReasonKind - * @see #setReasonKind(ForbiddenReasonKind) - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#getForbiddenEditPartPermutation_ReasonKind() - * @model default="invalid" required="true" ordered="false" - * @generated - */ - ForbiddenReasonKind getReasonKind(); - - /** - * Sets the value of the '{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPartPermutation#getReasonKind <em>Reason Kind</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param value - * the new value of the '<em>Reason Kind</em>' attribute. - * @see org.eclipse.papyrus.tests.framework.exceptions.ForbiddenReasonKind - * @see #getReasonKind() - * @generated - */ - void setReasonKind(ForbiddenReasonKind value); - - /** - * Returns the value of the '<em><b>Reason</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Reason</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * - * @return the value of the '<em>Reason</em>' attribute. - * @see #setReason(String) - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#getForbiddenEditPartPermutation_Reason() - * @model dataType="org.eclipse.uml2.types.String" ordered="false" - * @generated - */ - String getReason(); - - /** - * Sets the value of the '{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPartPermutation#getReason <em>Reason</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param value - * the new value of the '<em>Reason</em>' attribute. - * @see #getReason() - * @generated - */ - void setReason(String value); - - /** - * Returns the value of the '<em><b>Test Class</b></em>' reference list. - * The list contents are of type {@link org.eclipse.uml2.uml.Class}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Test Class</em>' reference list isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * - * @return the value of the '<em>Test Class</em>' reference list. - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#getForbiddenEditPartPermutation_TestClass() - * @model required="true" ordered="false" - * @generated - */ - EList<org.eclipse.uml2.uml.Class> getTestClasses(); - - /** - * Retrieves the first {@link org.eclipse.uml2.uml.Class} with the specified '<em><b>Name</b></em>' from the '<em><b>Test Class</b></em>' reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param name - * The '<em><b>Name</b></em>' of the {@link org.eclipse.uml2.uml.Class} to retrieve, or <code>null</code>. - * @return The first {@link org.eclipse.uml2.uml.Class} with the specified '<em><b>Name</b></em>', or <code>null</code>. - * @see #getTestClasses() - * @generated - */ - org.eclipse.uml2.uml.Class getTestClass(String name); - - /** - * Retrieves the first {@link org.eclipse.uml2.uml.Class} with the specified '<em><b>Name</b></em>' from the '<em><b>Test Class</b></em>' reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param name - * The '<em><b>Name</b></em>' of the {@link org.eclipse.uml2.uml.Class} to retrieve, or <code>null</code>. - * @param ignoreCase - * Whether to ignore case in {@link java.lang.String} comparisons. - * @param eClass - * The Ecore class of the {@link org.eclipse.uml2.uml.Class} to retrieve, or <code>null</code>. - * @return The first {@link org.eclipse.uml2.uml.Class} with the specified '<em><b>Name</b></em>', or <code>null</code>. - * @see #getTestClasses() - * @generated - */ - org.eclipse.uml2.uml.Class getTestClass(String name, boolean ignoreCase, EClass eClass); - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * <!-- begin-model-doc --> - * testClass->forAll(conformsTo(_'org.eclipse.papyrus.uml.diagram.tests'::AbstractPapyrusTestCase.oclAsType(UML::Type))) - * - * @param diagnostics - * The chain of diagnostics to which problems are to be appended. - * @param context - * The cache of context-specific information. - * <!-- end-model-doc --> - * @model annotation="http://www.eclipse.org/emf/2002/Ecore/OCL body='testClass->forAll(conformsTo(_\'org.eclipse.papyrus.uml.diagram.tests\'::AbstractPapyrusTestCase.oclAsType(UML::Type)))'" - * @generated - */ - boolean test_classes(DiagnosticChain diagnostics, Map<Object, Object> context); - -} // ForbiddenEditPartPermutation diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/ForbiddenReasonKind.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/ForbiddenReasonKind.java deleted file mode 100644 index 0cd9a17f211..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/ForbiddenReasonKind.java +++ /dev/null @@ -1,307 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions; - -import java.util.Arrays; -import java.util.Collections; -import java.util.List; - -import org.eclipse.emf.common.util.Enumerator; - -/** - * <!-- begin-user-doc --> - * A representation of the literals of the enumeration '<em><b>Forbidden Reason Kind</b></em>', - * and utility methods for working with them. - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#getForbiddenReasonKind() - * @model - * @generated - */ -public enum ForbiddenReasonKind implements Enumerator { - /** - * The '<em><b>Invalid</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #INVALID_VALUE - * @generated - * @ordered - */ - INVALID(0, "invalid", "invalid"), - - /** - * The '<em><b>Failing</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #FAILING_VALUE - * @generated - * @ordered - */ - FAILING(1, "failing", "failing"), - - /** - * The '<em><b>Unimplemented</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #UNIMPLEMENTED_VALUE - * @generated - * @ordered - */ - UNIMPLEMENTED(2, "unimplemented", "unimplemented"), /** - * The '<em><b>Interactive</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #INTERACTIVE_VALUE - * @generated - * @ordered - */ - INTERACTIVE(3, "interactive", "interactive"); - - /** - * The '<em><b>Invalid</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>Invalid</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * - * @see #INVALID - * @model name="invalid" - * @generated - * @ordered - */ - public static final int INVALID_VALUE = 0; - - /** - * The '<em><b>Failing</b></em>' literal value. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * <!-- begin-model-doc --> - * Indicates that the permutation of edit-parts is forbidden because the tests generated would fail. - * The system-under-test intends to support this permutation, but it does not work. - * <!-- end-model-doc --> - * - * @see #FAILING - * @model name="failing" - * @generated - * @ordered - */ - public static final int FAILING_VALUE = 1; - - /** - * The '<em><b>Unimplemented</b></em>' literal value. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * <!-- begin-model-doc --> - * Indicates that the permutation of edit-parts is forbidden because the - * system-under-test does not intend to support it, so generating tests - * would be pointless (they would only fail). - * <!-- end-model-doc --> - * - * @see #UNIMPLEMENTED - * @model name="unimplemented" - * @generated - * @ordered - */ - public static final int UNIMPLEMENTED_VALUE = 2; - - /** - * The '<em><b>Interactive</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>Interactive</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * - * @see #INTERACTIVE - * @model name="interactive" - * @generated - * @ordered - */ - public static final int INTERACTIVE_VALUE = 3; - - /** - * An array of all the '<em><b>Forbidden Reason Kind</b></em>' enumerators. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - private static final ForbiddenReasonKind[] VALUES_ARRAY = new ForbiddenReasonKind[] { - INVALID, - FAILING, - UNIMPLEMENTED, - INTERACTIVE, - }; - - /** - * A public read-only list of all the '<em><b>Forbidden Reason Kind</b></em>' enumerators. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public static final List<ForbiddenReasonKind> VALUES = Collections.unmodifiableList(Arrays.asList(VALUES_ARRAY)); - - /** - * Returns the '<em><b>Forbidden Reason Kind</b></em>' literal with the specified literal value. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param literal - * the literal. - * @return the matching enumerator or <code>null</code>. - * @generated - */ - public static ForbiddenReasonKind get(String literal) { - for (int i = 0; i < VALUES_ARRAY.length; ++i) { - ForbiddenReasonKind result = VALUES_ARRAY[i]; - if (result.toString().equals(literal)) { - return result; - } - } - return null; - } - - /** - * Returns the '<em><b>Forbidden Reason Kind</b></em>' literal with the specified name. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param name - * the name. - * @return the matching enumerator or <code>null</code>. - * @generated - */ - public static ForbiddenReasonKind getByName(String name) { - for (int i = 0; i < VALUES_ARRAY.length; ++i) { - ForbiddenReasonKind result = VALUES_ARRAY[i]; - if (result.getName().equals(name)) { - return result; - } - } - return null; - } - - /** - * Returns the '<em><b>Forbidden Reason Kind</b></em>' literal with the specified integer value. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param value - * the integer value. - * @return the matching enumerator or <code>null</code>. - * @generated - */ - public static ForbiddenReasonKind get(int value) { - switch (value) { - case INVALID_VALUE: - return INVALID; - case FAILING_VALUE: - return FAILING; - case UNIMPLEMENTED_VALUE: - return UNIMPLEMENTED; - case INTERACTIVE_VALUE: - return INTERACTIVE; - } - return null; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - private final int value; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - private final String name; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - private final String literal; - - /** - * Only this class can construct instances. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - private ForbiddenReasonKind(int value, String name, String literal) { - this.value = value; - this.name = name; - this.literal = literal; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public int getValue() { - return value; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public String getName() { - return name; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public String getLiteral() { - return literal; - } - - /** - * Returns the literal value of the enumerator, which is its string representation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public String toString() { - return literal; - } - -} // ForbiddenReasonKind diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/OperatorKind.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/OperatorKind.java deleted file mode 100644 index 9e060e8ae29..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/OperatorKind.java +++ /dev/null @@ -1,278 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions; - -import java.util.Arrays; -import java.util.Collections; -import java.util.List; - -import org.eclipse.emf.common.util.Enumerator; - -/** - * <!-- begin-user-doc --> - * A representation of the literals of the enumeration '<em><b>Operator Kind</b></em>', - * and utility methods for working with them. - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#getOperatorKind() - * @model - * @generated - */ -public enum OperatorKind implements Enumerator { - /** - * The '<em><b>And</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #AND_VALUE - * @generated - * @ordered - */ - AND(0, "and", "and"), - - /** - * The '<em><b>Or</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #OR_VALUE - * @generated - * @ordered - */ - OR(1, "or", "or"), - - /** - * The '<em><b>Not</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #NOT_VALUE - * @generated - * @ordered - */ - NOT(2, "not", "not"); - - /** - * The '<em><b>And</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>And</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * - * @see #AND - * @model name="and" - * @generated - * @ordered - */ - public static final int AND_VALUE = 0; - - /** - * The '<em><b>Or</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>Or</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * - * @see #OR - * @model name="or" - * @generated - * @ordered - */ - public static final int OR_VALUE = 1; - - /** - * The '<em><b>Not</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>Not</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * - * @see #NOT - * @model name="not" - * @generated - * @ordered - */ - public static final int NOT_VALUE = 2; - - /** - * An array of all the '<em><b>Operator Kind</b></em>' enumerators. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - private static final OperatorKind[] VALUES_ARRAY = new OperatorKind[] { - AND, - OR, - NOT, - }; - - /** - * A public read-only list of all the '<em><b>Operator Kind</b></em>' enumerators. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public static final List<OperatorKind> VALUES = Collections.unmodifiableList(Arrays.asList(VALUES_ARRAY)); - - /** - * Returns the '<em><b>Operator Kind</b></em>' literal with the specified literal value. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param literal - * the literal. - * @return the matching enumerator or <code>null</code>. - * @generated - */ - public static OperatorKind get(String literal) { - for (int i = 0; i < VALUES_ARRAY.length; ++i) { - OperatorKind result = VALUES_ARRAY[i]; - if (result.toString().equals(literal)) { - return result; - } - } - return null; - } - - /** - * Returns the '<em><b>Operator Kind</b></em>' literal with the specified name. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param name - * the name. - * @return the matching enumerator or <code>null</code>. - * @generated - */ - public static OperatorKind getByName(String name) { - for (int i = 0; i < VALUES_ARRAY.length; ++i) { - OperatorKind result = VALUES_ARRAY[i]; - if (result.getName().equals(name)) { - return result; - } - } - return null; - } - - /** - * Returns the '<em><b>Operator Kind</b></em>' literal with the specified integer value. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param value - * the integer value. - * @return the matching enumerator or <code>null</code>. - * @generated - */ - public static OperatorKind get(int value) { - switch (value) { - case AND_VALUE: - return AND; - case OR_VALUE: - return OR; - case NOT_VALUE: - return NOT; - } - return null; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - private final int value; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - private final String name; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - private final String literal; - - /** - * Only this class can construct instances. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - private OperatorKind(int value, String name, String literal) { - this.value = value; - this.name = name; - this.literal = literal; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public int getValue() { - return value; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public String getName() { - return name; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public String getLiteral() { - return literal; - } - - /** - * Returns the literal value of the enumerator, which is its string representation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public String toString() { - return literal; - } - -} // OperatorKind diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/TestConstraint.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/TestConstraint.java deleted file mode 100644 index 0dbadb62ece..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/TestConstraint.java +++ /dev/null @@ -1,108 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions; - -import org.eclipse.emf.common.util.DiagnosticChain; -import org.eclipse.emf.common.util.EList; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.uml2.uml.InstanceSpecification; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Test Constraint</b></em>'. - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * </p> - * <ul> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.TestConstraint#getContainer <em>Container</em>}</li> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.TestConstraint#isOmitOnFailure <em>Omit On Failure</em>}</li> - * </ul> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#getTestConstraint() - * @model abstract="true" - * @generated - */ -public interface TestConstraint extends EObject { - /** - * Returns the value of the '<em><b>Container</b></em>' container reference. - * It is bidirectional and its opposite is '{@link org.eclipse.papyrus.tests.framework.exceptions.TestExceptions#getConstraints <em>Constraint</em>}'. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Container</em>' container reference isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * - * @return the value of the '<em>Container</em>' container reference. - * @see #setContainer(TestExceptions) - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#getTestConstraint_Container() - * @see org.eclipse.papyrus.tests.framework.exceptions.TestExceptions#getConstraints - * @model opposite="constraint" required="true" transient="false" ordered="false" - * @generated - */ - TestExceptions getContainer(); - - /** - * Sets the value of the '{@link org.eclipse.papyrus.tests.framework.exceptions.TestConstraint#getContainer <em>Container</em>}' container reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param value - * the new value of the '<em>Container</em>' container reference. - * @see #getContainer() - * @generated - */ - void setContainer(TestExceptions value); - - /** - * Returns the value of the '<em><b>Omit On Failure</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Omit On Failure</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * - * @return the value of the '<em>Omit On Failure</em>' attribute. - * @see #setOmitOnFailure(boolean) - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#getTestConstraint_OmitOnFailure() - * @model dataType="org.eclipse.uml2.types.Boolean" required="true" ordered="false" - * @generated - */ - boolean isOmitOnFailure(); - - /** - * Sets the value of the '{@link org.eclipse.papyrus.tests.framework.exceptions.TestConstraint#isOmitOnFailure <em>Omit On Failure</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param value - * the new value of the '<em>Omit On Failure</em>' attribute. - * @see #isOmitOnFailure() - * @generated - */ - void setOmitOnFailure(boolean value); - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @model dataType="org.eclipse.uml2.types.Boolean" required="true" ordered="false" editPartUnique="false" editPartRequired="true" editPartMany="true" testClassRequired="true" testClassOrdered="false" diagnosticsRequired="true" diagnosticsOrdered="false" - * @generated - */ - boolean validate(EList<InstanceSpecification> editPart, org.eclipse.uml2.uml.Class testClass, DiagnosticChain diagnostics); - -} // TestConstraint diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/TestExceptions.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/TestExceptions.java deleted file mode 100644 index a334143702c..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/TestExceptions.java +++ /dev/null @@ -1,79 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions; - -import org.eclipse.emf.common.util.DiagnosticChain; -import org.eclipse.emf.common.util.EList; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.uml2.uml.InstanceSpecification; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Test Exceptions</b></em>'. - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * </p> - * <ul> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.TestExceptions#getConstraints <em>Constraint</em>}</li> - * </ul> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#getTestExceptions() - * @model - * @generated - */ -public interface TestExceptions extends EObject { - /** - * Returns the value of the '<em><b>Constraint</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.papyrus.tests.framework.exceptions.TestConstraint}. - * It is bidirectional and its opposite is '{@link org.eclipse.papyrus.tests.framework.exceptions.TestConstraint#getContainer <em>Container</em>}'. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Constraint</em>' containment reference list isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * - * @return the value of the '<em>Constraint</em>' containment reference list. - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#getTestExceptions_Constraint() - * @see org.eclipse.papyrus.tests.framework.exceptions.TestConstraint#getContainer - * @model opposite="container" containment="true" ordered="false" - * @generated - */ - EList<TestConstraint> getConstraints(); - - /** - * Creates a new {@link org.eclipse.papyrus.tests.framework.exceptions.TestConstraint} and appends it to the '<em><b>Constraint</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param eClass - * The Ecore class of the {@link org.eclipse.papyrus.tests.framework.exceptions.TestConstraint} to create. - * @return The new {@link org.eclipse.papyrus.tests.framework.exceptions.TestConstraint}. - * @see #getConstraints() - * @generated - */ - TestConstraint createConstraint(EClass eClass); - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @model dataType="org.eclipse.uml2.types.Boolean" required="true" ordered="false" editPartUnique="false" editPartRequired="true" editPartMany="true" testClassRequired="true" testClassOrdered="false" diagnosticsRequired="true" diagnosticsOrdered="false" - * @generated - */ - boolean validate(EList<InstanceSpecification> editPart, org.eclipse.uml2.uml.Class testClass, DiagnosticChain diagnostics); - -} // TestExceptions diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/AnyEditPartImpl.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/AnyEditPartImpl.java deleted file mode 100644 index fbbae171aa9..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/AnyEditPartImpl.java +++ /dev/null @@ -1,82 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions.impl; - -import java.lang.reflect.InvocationTargetException; - -import org.eclipse.emf.common.util.EList; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.papyrus.tests.framework.exceptions.AnyEditPart; -import org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage; - -import org.eclipse.papyrus.tests.framework.internal.exceptions.operations.AnyEditPartOperations; - -import org.eclipse.uml2.uml.InstanceSpecification; - -/** - * <!-- begin-user-doc --> - * An implementation of the model object '<em><b>Any Edit Part</b></em>'. - * <!-- end-user-doc --> - * - * @generated - */ -public class AnyEditPartImpl extends EditPartSpecImpl implements AnyEditPart { - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - protected AnyEditPartImpl() { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return ExceptionsPackage.Literals.ANY_EDIT_PART; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public boolean matches(InstanceSpecification editPart) { - return AnyEditPartOperations.matches(this, editPart); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public Object eInvoke(int operationID, EList<?> arguments) throws InvocationTargetException { - switch (operationID) { - case ExceptionsPackage.ANY_EDIT_PART___MATCHES__INSTANCESPECIFICATION: - return matches((InstanceSpecification) arguments.get(0)); - } - return super.eInvoke(operationID, arguments); - } - -} // AnyEditPartImpl diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/CompositeEditPartSpecImpl.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/CompositeEditPartSpecImpl.java deleted file mode 100644 index a79f24ab20f..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/CompositeEditPartSpecImpl.java +++ /dev/null @@ -1,304 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions.impl; - -import java.lang.reflect.InvocationTargetException; -import java.util.Collection; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.NotificationChain; -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.ecore.util.EObjectContainmentWithInverseEList; -import org.eclipse.emf.ecore.util.InternalEList; -import org.eclipse.papyrus.tests.framework.exceptions.CompositeEditPartSpec; -import org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec; -import org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage; -import org.eclipse.papyrus.tests.framework.exceptions.OperatorKind; -import org.eclipse.papyrus.tests.framework.internal.exceptions.operations.CompositeEditPartSpecOperations; -import org.eclipse.uml2.uml.InstanceSpecification; - -/** - * <!-- begin-user-doc --> - * An implementation of the model object '<em><b>Composite Edit Part Spec</b></em>'. - * <!-- end-user-doc --> - * <p> - * The following features are implemented: - * </p> - * <ul> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.impl.CompositeEditPartSpecImpl#getOperator <em>Operator</em>}</li> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.impl.CompositeEditPartSpecImpl#getOperands <em>Operand</em>}</li> - * </ul> - * - * @generated - */ -public class CompositeEditPartSpecImpl extends EditPartSpecImpl implements CompositeEditPartSpec { - /** - * The default value of the '{@link #getOperator() <em>Operator</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #getOperator() - * @generated - * @ordered - */ - protected static final OperatorKind OPERATOR_EDEFAULT = OperatorKind.AND; - - /** - * The cached value of the '{@link #getOperator() <em>Operator</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #getOperator() - * @generated - * @ordered - */ - protected OperatorKind operator = OPERATOR_EDEFAULT; - - /** - * The cached value of the '{@link #getOperands() <em>Operand</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #getOperands() - * @generated - * @ordered - */ - protected EList<EditPartSpec> operands; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - protected CompositeEditPartSpecImpl() { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return ExceptionsPackage.Literals.COMPOSITE_EDIT_PART_SPEC; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public OperatorKind getOperator() { - return operator; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public void setOperator(OperatorKind newOperator) { - OperatorKind oldOperator = operator; - operator = newOperator == null ? OPERATOR_EDEFAULT : newOperator; - if (eNotificationRequired()) { - eNotify(new ENotificationImpl(this, Notification.SET, ExceptionsPackage.COMPOSITE_EDIT_PART_SPEC__OPERATOR, oldOperator, operator)); - } - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EList<EditPartSpec> getOperands() { - if (operands == null) { - operands = new EObjectContainmentWithInverseEList<EditPartSpec>(EditPartSpec.class, this, ExceptionsPackage.COMPOSITE_EDIT_PART_SPEC__OPERAND, ExceptionsPackage.EDIT_PART_SPEC__COMPOSITE); - } - return operands; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EditPartSpec createOperand(EClass eClass) { - EditPartSpec newOperand = (EditPartSpec) create(eClass); - getOperands().add(newOperand); - return newOperand; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public boolean matches(InstanceSpecification editPart) { - return CompositeEditPartSpecOperations.matches(this, editPart); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { - switch (featureID) { - case ExceptionsPackage.COMPOSITE_EDIT_PART_SPEC__OPERAND: - return ((InternalEList<InternalEObject>) (InternalEList<?>) getOperands()).basicAdd(otherEnd, msgs); - } - return super.eInverseAdd(otherEnd, featureID, msgs); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { - switch (featureID) { - case ExceptionsPackage.COMPOSITE_EDIT_PART_SPEC__OPERAND: - return ((InternalEList<?>) getOperands()).basicRemove(otherEnd, 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 ExceptionsPackage.COMPOSITE_EDIT_PART_SPEC__OPERATOR: - return getOperator(); - case ExceptionsPackage.COMPOSITE_EDIT_PART_SPEC__OPERAND: - return getOperands(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case ExceptionsPackage.COMPOSITE_EDIT_PART_SPEC__OPERATOR: - setOperator((OperatorKind) newValue); - return; - case ExceptionsPackage.COMPOSITE_EDIT_PART_SPEC__OPERAND: - getOperands().clear(); - getOperands().addAll((Collection<? extends EditPartSpec>) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case ExceptionsPackage.COMPOSITE_EDIT_PART_SPEC__OPERATOR: - setOperator(OPERATOR_EDEFAULT); - return; - case ExceptionsPackage.COMPOSITE_EDIT_PART_SPEC__OPERAND: - getOperands().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case ExceptionsPackage.COMPOSITE_EDIT_PART_SPEC__OPERATOR: - return operator != OPERATOR_EDEFAULT; - case ExceptionsPackage.COMPOSITE_EDIT_PART_SPEC__OPERAND: - return operands != null && !operands.isEmpty(); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public Object eInvoke(int operationID, EList<?> arguments) throws InvocationTargetException { - switch (operationID) { - case ExceptionsPackage.COMPOSITE_EDIT_PART_SPEC___MATCHES__INSTANCESPECIFICATION: - return matches((InstanceSpecification) arguments.get(0)); - } - return super.eInvoke(operationID, arguments); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) { - return super.toString(); - } - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (operator: "); - result.append(operator); - result.append(')'); - return result.toString(); - } - -} // CompositeEditPartSpecImpl diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/EditPartRefImpl.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/EditPartRefImpl.java deleted file mode 100644 index 955271dec76..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/EditPartRefImpl.java +++ /dev/null @@ -1,209 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions.impl; - -import java.lang.reflect.InvocationTargetException; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.gmf.codegen.gmfgen.GenCommonBase; -import org.eclipse.papyrus.tests.framework.exceptions.EditPartRef; -import org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage; -import org.eclipse.papyrus.tests.framework.internal.exceptions.operations.EditPartRefOperations; -import org.eclipse.uml2.uml.InstanceSpecification; - -/** - * <!-- begin-user-doc --> - * An implementation of the model object '<em><b>Edit Part Ref</b></em>'. - * <!-- end-user-doc --> - * <p> - * The following features are implemented: - * </p> - * <ul> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.impl.EditPartRefImpl#getEditPart <em>Edit Part</em>}</li> - * </ul> - * - * @generated - */ -public class EditPartRefImpl extends EditPartSpecImpl implements EditPartRef { - /** - * The cached value of the '{@link #getEditPart() <em>Edit Part</em>}' reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #getEditPart() - * @generated - * @ordered - */ - protected GenCommonBase editPart; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - protected EditPartRefImpl() { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return ExceptionsPackage.Literals.EDIT_PART_REF; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public GenCommonBase getEditPart() { - if (editPart != null && editPart.eIsProxy()) { - InternalEObject oldEditPart = (InternalEObject) editPart; - editPart = (GenCommonBase) eResolveProxy(oldEditPart); - if (editPart != oldEditPart) { - if (eNotificationRequired()) { - eNotify(new ENotificationImpl(this, Notification.RESOLVE, ExceptionsPackage.EDIT_PART_REF__EDIT_PART, oldEditPart, editPart)); - } - } - } - return editPart; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public GenCommonBase basicGetEditPart() { - return editPart; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public void setEditPart(GenCommonBase newEditPart) { - GenCommonBase oldEditPart = editPart; - editPart = newEditPart; - if (eNotificationRequired()) { - eNotify(new ENotificationImpl(this, Notification.SET, ExceptionsPackage.EDIT_PART_REF__EDIT_PART, oldEditPart, editPart)); - } - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public boolean matches(InstanceSpecification editPart) { - return EditPartRefOperations.matches(this, editPart); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case ExceptionsPackage.EDIT_PART_REF__EDIT_PART: - if (resolve) { - return getEditPart(); - } - return basicGetEditPart(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case ExceptionsPackage.EDIT_PART_REF__EDIT_PART: - setEditPart((GenCommonBase) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case ExceptionsPackage.EDIT_PART_REF__EDIT_PART: - setEditPart((GenCommonBase) null); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case ExceptionsPackage.EDIT_PART_REF__EDIT_PART: - return editPart != 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 ExceptionsPackage.EDIT_PART_REF___MATCHES__INSTANCESPECIFICATION: - return matches((InstanceSpecification) arguments.get(0)); - } - return super.eInvoke(operationID, arguments); - } - -} // EditPartRefImpl diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/EditPartSpecImpl.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/EditPartSpecImpl.java deleted file mode 100644 index 349d9383d63..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/EditPartSpecImpl.java +++ /dev/null @@ -1,273 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions.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.util.EcoreUtil; - -import org.eclipse.papyrus.tests.framework.exceptions.CompositeEditPartSpec; -import org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec; -import org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage; -import org.eclipse.papyrus.tests.framework.internal.exceptions.operations.EditPartSpecOperations; - -import org.eclipse.uml2.uml.InstanceSpecification; - -/** - * <!-- begin-user-doc --> - * An implementation of the model object '<em><b>Edit Part Spec</b></em>'. - * <!-- end-user-doc --> - * <p> - * The following features are implemented: - * </p> - * <ul> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.impl.EditPartSpecImpl#getComposite <em>Composite</em>}</li> - * </ul> - * - * @generated - */ -public abstract class EditPartSpecImpl extends TestExceptionsObject implements EditPartSpec { - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - protected EditPartSpecImpl() { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return ExceptionsPackage.Literals.EDIT_PART_SPEC; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public CompositeEditPartSpec getComposite() { - if (eContainerFeatureID() != ExceptionsPackage.EDIT_PART_SPEC__COMPOSITE) { - return null; - } - return (CompositeEditPartSpec) eInternalContainer(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public NotificationChain basicSetComposite(CompositeEditPartSpec newComposite, NotificationChain msgs) { - msgs = eBasicSetContainer((InternalEObject) newComposite, ExceptionsPackage.EDIT_PART_SPEC__COMPOSITE, msgs); - return msgs; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public void setComposite(CompositeEditPartSpec newComposite) { - if (newComposite != eInternalContainer() || (eContainerFeatureID() != ExceptionsPackage.EDIT_PART_SPEC__COMPOSITE && newComposite != null)) { - if (EcoreUtil.isAncestor(this, newComposite)) { - throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); - } - NotificationChain msgs = null; - if (eInternalContainer() != null) { - msgs = eBasicRemoveFromContainer(msgs); - } - if (newComposite != null) { - msgs = ((InternalEObject) newComposite).eInverseAdd(this, ExceptionsPackage.COMPOSITE_EDIT_PART_SPEC__OPERAND, CompositeEditPartSpec.class, msgs); - } - msgs = basicSetComposite(newComposite, msgs); - if (msgs != null) { - msgs.dispatch(); - } - } else if (eNotificationRequired()) { - eNotify(new ENotificationImpl(this, Notification.SET, ExceptionsPackage.EDIT_PART_SPEC__COMPOSITE, newComposite, newComposite)); - } - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public boolean matches(InstanceSpecification editPart) { - return EditPartSpecOperations.matches(this, editPart); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { - switch (featureID) { - case ExceptionsPackage.EDIT_PART_SPEC__COMPOSITE: - if (eInternalContainer() != null) { - msgs = eBasicRemoveFromContainer(msgs); - } - return basicSetComposite((CompositeEditPartSpec) otherEnd, msgs); - } - return super.eInverseAdd(otherEnd, featureID, msgs); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { - switch (featureID) { - case ExceptionsPackage.EDIT_PART_SPEC__COMPOSITE: - return basicSetComposite(null, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { - switch (eContainerFeatureID()) { - case ExceptionsPackage.EDIT_PART_SPEC__COMPOSITE: - return eInternalContainer().eInverseRemove(this, ExceptionsPackage.COMPOSITE_EDIT_PART_SPEC__OPERAND, CompositeEditPartSpec.class, msgs); - } - return super.eBasicRemoveFromContainerFeature(msgs); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case ExceptionsPackage.EDIT_PART_SPEC__COMPOSITE: - return getComposite(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case ExceptionsPackage.EDIT_PART_SPEC__COMPOSITE: - setComposite((CompositeEditPartSpec) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case ExceptionsPackage.EDIT_PART_SPEC__COMPOSITE: - setComposite((CompositeEditPartSpec) null); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case ExceptionsPackage.EDIT_PART_SPEC__COMPOSITE: - return getComposite() != 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 ExceptionsPackage.EDIT_PART_SPEC___MATCHES__INSTANCESPECIFICATION: - return matches((InstanceSpecification) arguments.get(0)); - } - return super.eInvoke(operationID, arguments); - } - - /** - * 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); - } - -} // EditPartSpecImpl diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/ExceptionsFactoryImpl.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/ExceptionsFactoryImpl.java deleted file mode 100644 index 13a4c65aa7e..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/ExceptionsFactoryImpl.java +++ /dev/null @@ -1,268 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EDataType; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; - -import org.eclipse.emf.ecore.impl.EFactoryImpl; - -import org.eclipse.emf.ecore.plugin.EcorePlugin; - -import org.eclipse.papyrus.tests.framework.exceptions.*; - -/** - * <!-- begin-user-doc --> - * An implementation of the model <b>Factory</b>. - * <!-- end-user-doc --> - * - * @generated - */ -public class ExceptionsFactoryImpl extends EFactoryImpl implements ExceptionsFactory { - /** - * Creates the default factory implementation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public static ExceptionsFactory init() { - try { - ExceptionsFactory theExceptionsFactory = (ExceptionsFactory) EPackage.Registry.INSTANCE.getEFactory(ExceptionsPackage.eNS_URI); - if (theExceptionsFactory != null) { - return theExceptionsFactory; - } - } catch (Exception exception) { - EcorePlugin.INSTANCE.log(exception); - } - return new ExceptionsFactoryImpl(); - } - - /** - * Creates an instance of the factory. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public ExceptionsFactoryImpl() { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EObject create(EClass eClass) { - switch (eClass.getClassifierID()) { - case ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION: - return createForbiddenEditPartPermutation(); - case ExceptionsPackage.TEST_EXCEPTIONS: - return createTestExceptions(); - case ExceptionsPackage.COMPOSITE_EDIT_PART_SPEC: - return createCompositeEditPartSpec(); - case ExceptionsPackage.EDIT_PART_REF: - return createEditPartRef(); - case ExceptionsPackage.ANY_EDIT_PART: - return createAnyEditPart(); - case ExceptionsPackage.FORBIDDEN_EDIT_PART: - return createForbiddenEditPart(); - default: - throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); - } - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public Object createFromString(EDataType eDataType, String initialValue) { - switch (eDataType.getClassifierID()) { - case ExceptionsPackage.FORBIDDEN_REASON_KIND: - return createForbiddenReasonKindFromString(eDataType, initialValue); - case ExceptionsPackage.OPERATOR_KIND: - return createOperatorKindFromString(eDataType, initialValue); - default: - throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier"); - } - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public String convertToString(EDataType eDataType, Object instanceValue) { - switch (eDataType.getClassifierID()) { - case ExceptionsPackage.FORBIDDEN_REASON_KIND: - return convertForbiddenReasonKindToString(eDataType, instanceValue); - case ExceptionsPackage.OPERATOR_KIND: - return convertOperatorKindToString(eDataType, instanceValue); - default: - throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier"); - } - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public ForbiddenEditPartPermutation createForbiddenEditPartPermutation() { - ForbiddenEditPartPermutationImpl forbiddenEditPartPermutation = new ForbiddenEditPartPermutationImpl(); - return forbiddenEditPartPermutation; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public TestExceptions createTestExceptions() { - TestExceptionsImpl testExceptions = new TestExceptionsImpl(); - return testExceptions; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public CompositeEditPartSpec createCompositeEditPartSpec() { - CompositeEditPartSpecImpl compositeEditPartSpec = new CompositeEditPartSpecImpl(); - return compositeEditPartSpec; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EditPartRef createEditPartRef() { - EditPartRefImpl editPartRef = new EditPartRefImpl(); - return editPartRef; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public AnyEditPart createAnyEditPart() { - AnyEditPartImpl anyEditPart = new AnyEditPartImpl(); - return anyEditPart; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public ForbiddenEditPart createForbiddenEditPart() { - ForbiddenEditPartImpl forbiddenEditPart = new ForbiddenEditPartImpl(); - return forbiddenEditPart; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public ForbiddenReasonKind createForbiddenReasonKindFromString(EDataType eDataType, String initialValue) { - ForbiddenReasonKind result = ForbiddenReasonKind.get(initialValue); - if (result == null) { - throw new IllegalArgumentException("The value '" + initialValue + "' is not a valid enumerator of '" + eDataType.getName() + "'"); - } - return result; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public String convertForbiddenReasonKindToString(EDataType eDataType, Object instanceValue) { - return instanceValue == null ? null : instanceValue.toString(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public OperatorKind createOperatorKindFromString(EDataType eDataType, String initialValue) { - OperatorKind result = OperatorKind.get(initialValue); - if (result == null) { - throw new IllegalArgumentException("The value '" + initialValue + "' is not a valid enumerator of '" + eDataType.getName() + "'"); - } - return result; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public String convertOperatorKindToString(EDataType eDataType, Object instanceValue) { - return instanceValue == null ? null : instanceValue.toString(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public ExceptionsPackage getExceptionsPackage() { - return (ExceptionsPackage) getEPackage(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @deprecated - * @generated - */ - @Deprecated - public static ExceptionsPackage getPackage() { - return ExceptionsPackage.eINSTANCE; - } - -} // ExceptionsFactoryImpl diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/ExceptionsPackageImpl.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/ExceptionsPackageImpl.java deleted file mode 100644 index 71a5e153c76..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/ExceptionsPackageImpl.java +++ /dev/null @@ -1,790 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions.impl; - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EEnum; -import org.eclipse.emf.ecore.EGenericType; -import org.eclipse.emf.ecore.EOperation; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.EValidator; - -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.impl.EPackageImpl; - -import org.eclipse.gmf.codegen.gmfgen.GMFGenPackage; - -import org.eclipse.papyrus.tests.framework.exceptions.AnyEditPart; -import org.eclipse.papyrus.tests.framework.exceptions.CompositeEditPartSpec; -import org.eclipse.papyrus.tests.framework.exceptions.EditPartRef; -import org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec; -import org.eclipse.papyrus.tests.framework.exceptions.ExceptionsFactory; -import org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage; -import org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPart; -import org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPartPermutation; -import org.eclipse.papyrus.tests.framework.exceptions.ForbiddenReasonKind; - -import org.eclipse.papyrus.tests.framework.exceptions.OperatorKind; -import org.eclipse.papyrus.tests.framework.exceptions.TestConstraint; -import org.eclipse.papyrus.tests.framework.exceptions.TestExceptions; -import org.eclipse.papyrus.tests.framework.exceptions.util.ExceptionsValidator; - -import org.eclipse.uml2.types.TypesPackage; - -import org.eclipse.uml2.uml.UMLPackage; - -/** - * <!-- begin-user-doc --> - * An implementation of the model <b>Package</b>. - * <!-- end-user-doc --> - * - * @generated - */ -public class ExceptionsPackageImpl extends EPackageImpl implements ExceptionsPackage { - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - private EClass forbiddenEditPartPermutationEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - private EClass testConstraintEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - private EClass testExceptionsEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - private EClass editPartSpecEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - private EClass compositeEditPartSpecEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - private EClass editPartRefEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - private EClass anyEditPartEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - private EClass forbiddenEditPartEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - private EEnum forbiddenReasonKindEEnum = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - private EEnum operatorKindEEnum = null; - - /** - * Creates an instance of the model <b>Package</b>, registered with - * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package - * package URI value. - * <p> - * Note: the correct way to create the package is via the static - * factory method {@link #init init()}, which also performs - * initialization of the package, or returns the registered package, - * if one already exists. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see org.eclipse.emf.ecore.EPackage.Registry - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage#eNS_URI - * @see #init() - * @generated - */ - private ExceptionsPackageImpl() { - super(eNS_URI, ExceptionsFactory.eINSTANCE); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - private static boolean isInited = false; - - /** - * Creates, registers, and initializes the <b>Package</b> for this model, and for any others upon which it depends. - * - * <p> - * This method is used to initialize {@link ExceptionsPackage#eINSTANCE} when that field is accessed. - * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #eNS_URI - * @see #createPackageContents() - * @see #initializePackageContents() - * @generated - */ - public static ExceptionsPackage init() { - if (isInited) { - return (ExceptionsPackage) EPackage.Registry.INSTANCE.getEPackage(ExceptionsPackage.eNS_URI); - } - - // Obtain or create and register package - ExceptionsPackageImpl theExceptionsPackage = (ExceptionsPackageImpl) (EPackage.Registry.INSTANCE.get(eNS_URI) instanceof ExceptionsPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) : new ExceptionsPackageImpl()); - - isInited = true; - - // Initialize simple dependencies - GMFGenPackage.eINSTANCE.eClass(); - UMLPackage.eINSTANCE.eClass(); - - // Create package meta-data objects - theExceptionsPackage.createPackageContents(); - - // Initialize created meta-data - theExceptionsPackage.initializePackageContents(); - - // Register package validator - EValidator.Registry.INSTANCE.put(theExceptionsPackage, - new EValidator.Descriptor() { - @Override - public EValidator getEValidator() { - return ExceptionsValidator.INSTANCE; - } - }); - - // Mark meta-data to indicate it can't be changed - theExceptionsPackage.freeze(); - - - // Update the registry and return the package - EPackage.Registry.INSTANCE.put(ExceptionsPackage.eNS_URI, theExceptionsPackage); - return theExceptionsPackage; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EClass getForbiddenEditPartPermutation() { - return forbiddenEditPartPermutationEClass; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EReference getForbiddenEditPartPermutation_EditPart() { - return (EReference) forbiddenEditPartPermutationEClass.getEStructuralFeatures().get(3); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EAttribute getForbiddenEditPartPermutation_ReasonKind() { - return (EAttribute) forbiddenEditPartPermutationEClass.getEStructuralFeatures().get(0); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EAttribute getForbiddenEditPartPermutation_Reason() { - return (EAttribute) forbiddenEditPartPermutationEClass.getEStructuralFeatures().get(1); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EReference getForbiddenEditPartPermutation_TestClass() { - return (EReference) forbiddenEditPartPermutationEClass.getEStructuralFeatures().get(2); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EOperation getForbiddenEditPartPermutation__Test_classes__DiagnosticChain_Map() { - return forbiddenEditPartPermutationEClass.getEOperations().get(0); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EClass getTestConstraint() { - return testConstraintEClass; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EReference getTestConstraint_Container() { - return (EReference) testConstraintEClass.getEStructuralFeatures().get(0); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EAttribute getTestConstraint_OmitOnFailure() { - return (EAttribute) testConstraintEClass.getEStructuralFeatures().get(1); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EOperation getTestConstraint__Validate__EList_Class_DiagnosticChain() { - return testConstraintEClass.getEOperations().get(0); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EClass getTestExceptions() { - return testExceptionsEClass; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EReference getTestExceptions_Constraint() { - return (EReference) testExceptionsEClass.getEStructuralFeatures().get(0); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EOperation getTestExceptions__Validate__EList_Class_DiagnosticChain() { - return testExceptionsEClass.getEOperations().get(0); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EClass getEditPartSpec() { - return editPartSpecEClass; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EReference getEditPartSpec_Composite() { - return (EReference) editPartSpecEClass.getEStructuralFeatures().get(0); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EOperation getEditPartSpec__Matches__InstanceSpecification() { - return editPartSpecEClass.getEOperations().get(0); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EClass getCompositeEditPartSpec() { - return compositeEditPartSpecEClass; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EAttribute getCompositeEditPartSpec_Operator() { - return (EAttribute) compositeEditPartSpecEClass.getEStructuralFeatures().get(0); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EReference getCompositeEditPartSpec_Operand() { - return (EReference) compositeEditPartSpecEClass.getEStructuralFeatures().get(1); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EClass getEditPartRef() { - return editPartRefEClass; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EReference getEditPartRef_EditPart() { - return (EReference) editPartRefEClass.getEStructuralFeatures().get(0); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EClass getAnyEditPart() { - return anyEditPartEClass; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EClass getForbiddenEditPart() { - return forbiddenEditPartEClass; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EReference getForbiddenEditPart_EditPart() { - return (EReference) forbiddenEditPartEClass.getEStructuralFeatures().get(0); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EAttribute getForbiddenEditPart_Reason() { - return (EAttribute) forbiddenEditPartEClass.getEStructuralFeatures().get(1); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EAttribute getForbiddenEditPart_ReasonKind() { - return (EAttribute) forbiddenEditPartEClass.getEStructuralFeatures().get(2); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EEnum getForbiddenReasonKind() { - return forbiddenReasonKindEEnum; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EEnum getOperatorKind() { - return operatorKindEEnum; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public ExceptionsFactory getExceptionsFactory() { - return (ExceptionsFactory) getEFactoryInstance(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - private boolean isCreated = false; - - /** - * Creates the meta-model objects for the package. This method is - * guarded to have no affect on any invocation but its first. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public void createPackageContents() { - if (isCreated) { - return; - } - isCreated = true; - - // Create classes and their features - forbiddenEditPartPermutationEClass = createEClass(FORBIDDEN_EDIT_PART_PERMUTATION); - createEAttribute(forbiddenEditPartPermutationEClass, FORBIDDEN_EDIT_PART_PERMUTATION__REASON_KIND); - createEAttribute(forbiddenEditPartPermutationEClass, FORBIDDEN_EDIT_PART_PERMUTATION__REASON); - createEReference(forbiddenEditPartPermutationEClass, FORBIDDEN_EDIT_PART_PERMUTATION__TEST_CLASS); - createEReference(forbiddenEditPartPermutationEClass, FORBIDDEN_EDIT_PART_PERMUTATION__EDIT_PART); - createEOperation(forbiddenEditPartPermutationEClass, FORBIDDEN_EDIT_PART_PERMUTATION___TEST_CLASSES__DIAGNOSTICCHAIN_MAP); - - testConstraintEClass = createEClass(TEST_CONSTRAINT); - createEReference(testConstraintEClass, TEST_CONSTRAINT__CONTAINER); - createEAttribute(testConstraintEClass, TEST_CONSTRAINT__OMIT_ON_FAILURE); - createEOperation(testConstraintEClass, TEST_CONSTRAINT___VALIDATE__ELIST_CLASS_DIAGNOSTICCHAIN); - - testExceptionsEClass = createEClass(TEST_EXCEPTIONS); - createEReference(testExceptionsEClass, TEST_EXCEPTIONS__CONSTRAINT); - createEOperation(testExceptionsEClass, TEST_EXCEPTIONS___VALIDATE__ELIST_CLASS_DIAGNOSTICCHAIN); - - editPartSpecEClass = createEClass(EDIT_PART_SPEC); - createEReference(editPartSpecEClass, EDIT_PART_SPEC__COMPOSITE); - createEOperation(editPartSpecEClass, EDIT_PART_SPEC___MATCHES__INSTANCESPECIFICATION); - - compositeEditPartSpecEClass = createEClass(COMPOSITE_EDIT_PART_SPEC); - createEAttribute(compositeEditPartSpecEClass, COMPOSITE_EDIT_PART_SPEC__OPERATOR); - createEReference(compositeEditPartSpecEClass, COMPOSITE_EDIT_PART_SPEC__OPERAND); - - editPartRefEClass = createEClass(EDIT_PART_REF); - createEReference(editPartRefEClass, EDIT_PART_REF__EDIT_PART); - - anyEditPartEClass = createEClass(ANY_EDIT_PART); - - forbiddenEditPartEClass = createEClass(FORBIDDEN_EDIT_PART); - createEReference(forbiddenEditPartEClass, FORBIDDEN_EDIT_PART__EDIT_PART); - createEAttribute(forbiddenEditPartEClass, FORBIDDEN_EDIT_PART__REASON); - createEAttribute(forbiddenEditPartEClass, FORBIDDEN_EDIT_PART__REASON_KIND); - - // Create enums - forbiddenReasonKindEEnum = createEEnum(FORBIDDEN_REASON_KIND); - operatorKindEEnum = createEEnum(OPERATOR_KIND); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - private boolean isInitialized = false; - - /** - * Complete the initialization of the package and its meta-model. This - * method is guarded to have no affect on any invocation but its first. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public void initializePackageContents() { - if (isInitialized) { - return; - } - isInitialized = true; - - // Initialize package - setName(eNAME); - setNsPrefix(eNS_PREFIX); - setNsURI(eNS_URI); - - // Obtain other dependent packages - TypesPackage theTypesPackage = (TypesPackage) EPackage.Registry.INSTANCE.getEPackage(TypesPackage.eNS_URI); - UMLPackage theUMLPackage = (UMLPackage) EPackage.Registry.INSTANCE.getEPackage(UMLPackage.eNS_URI); - EcorePackage theEcorePackage = (EcorePackage) EPackage.Registry.INSTANCE.getEPackage(EcorePackage.eNS_URI); - GMFGenPackage theGMFGenPackage = (GMFGenPackage) EPackage.Registry.INSTANCE.getEPackage(GMFGenPackage.eNS_URI); - - // Create type parameters - - // Set bounds for type parameters - - // Add supertypes to classes - forbiddenEditPartPermutationEClass.getESuperTypes().add(this.getTestConstraint()); - compositeEditPartSpecEClass.getESuperTypes().add(this.getEditPartSpec()); - editPartRefEClass.getESuperTypes().add(this.getEditPartSpec()); - anyEditPartEClass.getESuperTypes().add(this.getEditPartSpec()); - forbiddenEditPartEClass.getESuperTypes().add(this.getTestConstraint()); - - // Initialize classes, features, and operations; add parameters - initEClass(forbiddenEditPartPermutationEClass, ForbiddenEditPartPermutation.class, "ForbiddenEditPartPermutation", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getForbiddenEditPartPermutation_ReasonKind(), this.getForbiddenReasonKind(), "reasonKind", "invalid", 1, 1, ForbiddenEditPartPermutation.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, - !IS_ORDERED); - initEAttribute(getForbiddenEditPartPermutation_Reason(), theTypesPackage.getString(), "reason", null, 0, 1, ForbiddenEditPartPermutation.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); - initEReference(getForbiddenEditPartPermutation_TestClass(), theUMLPackage.getClass_(), null, "testClass", null, 1, -1, ForbiddenEditPartPermutation.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, - IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); - initEReference(getForbiddenEditPartPermutation_EditPart(), this.getEditPartSpec(), null, "editPart", null, 1, -1, ForbiddenEditPartPermutation.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, - IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); - - EOperation op = initEOperation(getForbiddenEditPartPermutation__Test_classes__DiagnosticChain_Map(), ecorePackage.getEBoolean(), "test_classes", 0, 1, IS_UNIQUE, IS_ORDERED); - addEParameter(op, ecorePackage.getEDiagnosticChain(), "diagnostics", 0, 1, IS_UNIQUE, IS_ORDERED); - EGenericType g1 = createEGenericType(ecorePackage.getEMap()); - EGenericType g2 = createEGenericType(ecorePackage.getEJavaObject()); - g1.getETypeArguments().add(g2); - g2 = createEGenericType(ecorePackage.getEJavaObject()); - g1.getETypeArguments().add(g2); - addEParameter(op, g1, "context", 0, 1, IS_UNIQUE, IS_ORDERED); - - initEClass(testConstraintEClass, TestConstraint.class, "TestConstraint", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getTestConstraint_Container(), this.getTestExceptions(), this.getTestExceptions_Constraint(), "container", null, 1, 1, TestConstraint.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, - IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); - initEAttribute(getTestConstraint_OmitOnFailure(), theTypesPackage.getBoolean(), "omitOnFailure", null, 1, 1, TestConstraint.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); - - op = initEOperation(getTestConstraint__Validate__EList_Class_DiagnosticChain(), theTypesPackage.getBoolean(), "validate", 1, 1, IS_UNIQUE, !IS_ORDERED); - addEParameter(op, theUMLPackage.getInstanceSpecification(), "editPart", 1, -1, !IS_UNIQUE, IS_ORDERED); - addEParameter(op, theUMLPackage.getClass_(), "testClass", 1, 1, IS_UNIQUE, !IS_ORDERED); - addEParameter(op, theEcorePackage.getEDiagnosticChain(), "diagnostics", 1, 1, IS_UNIQUE, !IS_ORDERED); - - initEClass(testExceptionsEClass, TestExceptions.class, "TestExceptions", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getTestExceptions_Constraint(), this.getTestConstraint(), this.getTestConstraint_Container(), "constraint", null, 0, -1, TestExceptions.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, - IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); - - op = initEOperation(getTestExceptions__Validate__EList_Class_DiagnosticChain(), theTypesPackage.getBoolean(), "validate", 1, 1, IS_UNIQUE, !IS_ORDERED); - addEParameter(op, theUMLPackage.getInstanceSpecification(), "editPart", 1, -1, !IS_UNIQUE, IS_ORDERED); - addEParameter(op, theUMLPackage.getClass_(), "testClass", 1, 1, IS_UNIQUE, !IS_ORDERED); - addEParameter(op, theEcorePackage.getEDiagnosticChain(), "diagnostics", 1, 1, IS_UNIQUE, !IS_ORDERED); - - initEClass(editPartSpecEClass, EditPartSpec.class, "EditPartSpec", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getEditPartSpec_Composite(), this.getCompositeEditPartSpec(), this.getCompositeEditPartSpec_Operand(), "composite", null, 0, 1, EditPartSpec.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); - - op = initEOperation(getEditPartSpec__Matches__InstanceSpecification(), theTypesPackage.getBoolean(), "matches", 1, 1, IS_UNIQUE, !IS_ORDERED); - addEParameter(op, theUMLPackage.getInstanceSpecification(), "editPart", 1, 1, IS_UNIQUE, !IS_ORDERED); - - initEClass(compositeEditPartSpecEClass, CompositeEditPartSpec.class, "CompositeEditPartSpec", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getCompositeEditPartSpec_Operator(), this.getOperatorKind(), "operator", null, 1, 1, CompositeEditPartSpec.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); - initEReference(getCompositeEditPartSpec_Operand(), this.getEditPartSpec(), this.getEditPartSpec_Composite(), "operand", null, 1, -1, CompositeEditPartSpec.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); - - initEClass(editPartRefEClass, EditPartRef.class, "EditPartRef", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getEditPartRef_EditPart(), theGMFGenPackage.getGenCommonBase(), null, "editPart", null, 1, 1, EditPartRef.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, - !IS_ORDERED); - - initEClass(anyEditPartEClass, AnyEditPart.class, "AnyEditPart", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(forbiddenEditPartEClass, ForbiddenEditPart.class, "ForbiddenEditPart", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getForbiddenEditPart_EditPart(), this.getEditPartSpec(), null, "editPart", null, 1, 1, ForbiddenEditPart.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, - !IS_ORDERED); - initEAttribute(getForbiddenEditPart_Reason(), theTypesPackage.getString(), "reason", null, 0, 1, ForbiddenEditPart.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); - initEAttribute(getForbiddenEditPart_ReasonKind(), this.getForbiddenReasonKind(), "reasonKind", "invalid", 1, 1, ForbiddenEditPart.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); - - // Initialize enums and add enum literals - initEEnum(forbiddenReasonKindEEnum, ForbiddenReasonKind.class, "ForbiddenReasonKind"); - addEEnumLiteral(forbiddenReasonKindEEnum, ForbiddenReasonKind.INVALID); - addEEnumLiteral(forbiddenReasonKindEEnum, ForbiddenReasonKind.FAILING); - addEEnumLiteral(forbiddenReasonKindEEnum, ForbiddenReasonKind.UNIMPLEMENTED); - addEEnumLiteral(forbiddenReasonKindEEnum, ForbiddenReasonKind.INTERACTIVE); - - initEEnum(operatorKindEEnum, OperatorKind.class, "OperatorKind"); - addEEnumLiteral(operatorKindEEnum, OperatorKind.AND); - addEEnumLiteral(operatorKindEEnum, OperatorKind.OR); - addEEnumLiteral(operatorKindEEnum, OperatorKind.NOT); - - // Create resource - createResource(eNS_URI); - - // Create annotations - // http://www.eclipse.org/emf/2002/Ecore - createEcoreAnnotations(); - // duplicates - createDuplicatesAnnotations(); - // http://www.eclipse.org/emf/2002/Ecore/OCL - createOCLAnnotations(); - } - - /** - * Initializes the annotations for <b>http://www.eclipse.org/emf/2002/Ecore</b>. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - protected void createEcoreAnnotations() { - String source = "http://www.eclipse.org/emf/2002/Ecore"; - addAnnotation(this, - source, - new String[] { - "validationDelegates", "http://www.eclipse.org/emf/2002/Ecore/OCL" - }); - } - - /** - * Initializes the annotations for <b>duplicates</b>. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - protected void createDuplicatesAnnotations() { - String source = "duplicates"; - addAnnotation(forbiddenEditPartPermutationEClass, - source, - new String[] { - }); - addAnnotation(compositeEditPartSpecEClass, - source, - new String[] { - }); - addAnnotation(editPartRefEClass, - source, - new String[] { - }); - addAnnotation(anyEditPartEClass, - source, - new String[] { - }); - addAnnotation(forbiddenEditPartEClass, - source, - new String[] { - }); - } - - /** - * Initializes the annotations for <b>http://www.eclipse.org/emf/2002/Ecore/OCL</b>. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - protected void createOCLAnnotations() { - String source = "http://www.eclipse.org/emf/2002/Ecore/OCL"; - addAnnotation(getForbiddenEditPartPermutation__Test_classes__DiagnosticChain_Map(), - source, - new String[] { - "body", "testClass->forAll(conformsTo(_\'org.eclipse.papyrus.uml.diagram.tests\'::AbstractPapyrusTestCase.oclAsType(UML::Type)))" - }); - } - -} // ExceptionsPackageImpl diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/ForbiddenEditPartImpl.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/ForbiddenEditPartImpl.java deleted file mode 100644 index 628c24b7960..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/ForbiddenEditPartImpl.java +++ /dev/null @@ -1,394 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions.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.DiagnosticChain; -import org.eclipse.emf.common.util.EList; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -import org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec; -import org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage; -import org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPart; -import org.eclipse.papyrus.tests.framework.exceptions.ForbiddenReasonKind; - -import org.eclipse.papyrus.tests.framework.internal.exceptions.operations.ForbiddenEditPartOperations; - -import org.eclipse.uml2.uml.InstanceSpecification; - -/** - * <!-- begin-user-doc --> - * An implementation of the model object '<em><b>Forbidden Edit Part</b></em>'. - * <!-- end-user-doc --> - * <p> - * The following features are implemented: - * </p> - * <ul> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.impl.ForbiddenEditPartImpl#getEditPart <em>Edit Part</em>}</li> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.impl.ForbiddenEditPartImpl#getReason <em>Reason</em>}</li> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.impl.ForbiddenEditPartImpl#getReasonKind <em>Reason Kind</em>}</li> - * </ul> - * - * @generated - */ -public class ForbiddenEditPartImpl extends TestConstraintImpl implements ForbiddenEditPart { - /** - * The cached value of the '{@link #getEditPart() <em>Edit Part</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #getEditPart() - * @generated - * @ordered - */ - protected EditPartSpec editPart; - - /** - * The default value of the '{@link #getReason() <em>Reason</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #getReason() - * @generated - * @ordered - */ - protected static final String REASON_EDEFAULT = null; - - /** - * The cached value of the '{@link #getReason() <em>Reason</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #getReason() - * @generated - * @ordered - */ - protected String reason = REASON_EDEFAULT; - - /** - * The default value of the '{@link #getReasonKind() <em>Reason Kind</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #getReasonKind() - * @generated - * @ordered - */ - protected static final ForbiddenReasonKind REASON_KIND_EDEFAULT = ForbiddenReasonKind.INVALID; - - /** - * The cached value of the '{@link #getReasonKind() <em>Reason Kind</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #getReasonKind() - * @generated - * @ordered - */ - protected ForbiddenReasonKind reasonKind = REASON_KIND_EDEFAULT; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - protected ForbiddenEditPartImpl() { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return ExceptionsPackage.Literals.FORBIDDEN_EDIT_PART; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EditPartSpec getEditPart() { - return editPart; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public NotificationChain basicSetEditPart(EditPartSpec newEditPart, NotificationChain msgs) { - EditPartSpec oldEditPart = editPart; - editPart = newEditPart; - if (eNotificationRequired()) { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, ExceptionsPackage.FORBIDDEN_EDIT_PART__EDIT_PART, oldEditPart, newEditPart); - if (msgs == null) { - msgs = notification; - } else { - msgs.add(notification); - } - } - return msgs; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public void setEditPart(EditPartSpec newEditPart) { - if (newEditPart != editPart) { - NotificationChain msgs = null; - if (editPart != null) { - msgs = ((InternalEObject) editPart).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - ExceptionsPackage.FORBIDDEN_EDIT_PART__EDIT_PART, null, msgs); - } - if (newEditPart != null) { - msgs = ((InternalEObject) newEditPart).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - ExceptionsPackage.FORBIDDEN_EDIT_PART__EDIT_PART, null, msgs); - } - msgs = basicSetEditPart(newEditPart, msgs); - if (msgs != null) { - msgs.dispatch(); - } - } else if (eNotificationRequired()) { - eNotify(new ENotificationImpl(this, Notification.SET, ExceptionsPackage.FORBIDDEN_EDIT_PART__EDIT_PART, newEditPart, newEditPart)); - } - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EditPartSpec createEditPart(EClass eClass) { - EditPartSpec newEditPart = (EditPartSpec) create(eClass); - setEditPart(newEditPart); - return newEditPart; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public String getReason() { - return reason; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public void setReason(String newReason) { - String oldReason = reason; - reason = newReason; - if (eNotificationRequired()) { - eNotify(new ENotificationImpl(this, Notification.SET, ExceptionsPackage.FORBIDDEN_EDIT_PART__REASON, oldReason, reason)); - } - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public ForbiddenReasonKind getReasonKind() { - return reasonKind; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public void setReasonKind(ForbiddenReasonKind newReasonKind) { - ForbiddenReasonKind oldReasonKind = reasonKind; - reasonKind = newReasonKind == null ? REASON_KIND_EDEFAULT : newReasonKind; - if (eNotificationRequired()) { - eNotify(new ENotificationImpl(this, Notification.SET, ExceptionsPackage.FORBIDDEN_EDIT_PART__REASON_KIND, oldReasonKind, reasonKind)); - } - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public boolean validate(EList<InstanceSpecification> editPart, org.eclipse.uml2.uml.Class testClass, DiagnosticChain diagnostics) { - return ForbiddenEditPartOperations.validate(this, editPart, testClass, diagnostics); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { - switch (featureID) { - case ExceptionsPackage.FORBIDDEN_EDIT_PART__EDIT_PART: - return basicSetEditPart(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 ExceptionsPackage.FORBIDDEN_EDIT_PART__EDIT_PART: - return getEditPart(); - case ExceptionsPackage.FORBIDDEN_EDIT_PART__REASON: - return getReason(); - case ExceptionsPackage.FORBIDDEN_EDIT_PART__REASON_KIND: - return getReasonKind(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case ExceptionsPackage.FORBIDDEN_EDIT_PART__EDIT_PART: - setEditPart((EditPartSpec) newValue); - return; - case ExceptionsPackage.FORBIDDEN_EDIT_PART__REASON: - setReason((String) newValue); - return; - case ExceptionsPackage.FORBIDDEN_EDIT_PART__REASON_KIND: - setReasonKind((ForbiddenReasonKind) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case ExceptionsPackage.FORBIDDEN_EDIT_PART__EDIT_PART: - setEditPart((EditPartSpec) null); - return; - case ExceptionsPackage.FORBIDDEN_EDIT_PART__REASON: - setReason(REASON_EDEFAULT); - return; - case ExceptionsPackage.FORBIDDEN_EDIT_PART__REASON_KIND: - setReasonKind(REASON_KIND_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case ExceptionsPackage.FORBIDDEN_EDIT_PART__EDIT_PART: - return editPart != null; - case ExceptionsPackage.FORBIDDEN_EDIT_PART__REASON: - return REASON_EDEFAULT == null ? reason != null : !REASON_EDEFAULT.equals(reason); - case ExceptionsPackage.FORBIDDEN_EDIT_PART__REASON_KIND: - return reasonKind != REASON_KIND_EDEFAULT; - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - @SuppressWarnings("unchecked") - public Object eInvoke(int operationID, EList<?> arguments) throws InvocationTargetException { - switch (operationID) { - case ExceptionsPackage.FORBIDDEN_EDIT_PART___VALIDATE__ELIST_CLASS_DIAGNOSTICCHAIN: - return validate((EList<InstanceSpecification>) arguments.get(0), (org.eclipse.uml2.uml.Class) arguments.get(1), (DiagnosticChain) arguments.get(2)); - } - return super.eInvoke(operationID, arguments); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) { - return super.toString(); - } - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (reason: "); - result.append(reason); - result.append(", reasonKind: "); - result.append(reasonKind); - result.append(')'); - return result.toString(); - } - -} // ForbiddenEditPartImpl diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/ForbiddenEditPartPermutationImpl.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/ForbiddenEditPartPermutationImpl.java deleted file mode 100644 index b2bc965c5c4..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/ForbiddenEditPartPermutationImpl.java +++ /dev/null @@ -1,460 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions.impl; - -import java.lang.reflect.InvocationTargetException; - -import java.util.Collection; -import java.util.Map; - -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.notify.NotificationChain; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.DiagnosticChain; -import org.eclipse.emf.common.util.EList; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.ecore.util.EObjectContainmentEList; -import org.eclipse.emf.ecore.util.EObjectResolvingEList; -import org.eclipse.emf.ecore.util.InternalEList; -import org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec; -import org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage; -import org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPartPermutation; -import org.eclipse.papyrus.tests.framework.exceptions.ForbiddenReasonKind; - -import org.eclipse.papyrus.tests.framework.exceptions.util.ExceptionsValidator; -import org.eclipse.papyrus.tests.framework.internal.exceptions.operations.ForbiddenEditPartPermutationOperations; -import org.eclipse.uml2.uml.InstanceSpecification; - -/** - * <!-- begin-user-doc --> - * An implementation of the model object '<em><b>Forbidden Edit Part Permutation</b></em>'. - * <!-- end-user-doc --> - * <p> - * The following features are implemented: - * </p> - * <ul> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.impl.ForbiddenEditPartPermutationImpl#getReasonKind <em>Reason Kind</em>}</li> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.impl.ForbiddenEditPartPermutationImpl#getReason <em>Reason</em>}</li> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.impl.ForbiddenEditPartPermutationImpl#getTestClasses <em>Test Class</em>}</li> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.impl.ForbiddenEditPartPermutationImpl#getEditParts <em>Edit Part</em>}</li> - * </ul> - * - * @generated - */ -public class ForbiddenEditPartPermutationImpl extends TestConstraintImpl implements ForbiddenEditPartPermutation { - /** - * The default value of the '{@link #getReasonKind() <em>Reason Kind</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #getReasonKind() - * @generated - * @ordered - */ - protected static final ForbiddenReasonKind REASON_KIND_EDEFAULT = ForbiddenReasonKind.INVALID; - - /** - * The cached value of the '{@link #getReasonKind() <em>Reason Kind</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #getReasonKind() - * @generated - * @ordered - */ - protected ForbiddenReasonKind reasonKind = REASON_KIND_EDEFAULT; - - /** - * The default value of the '{@link #getReason() <em>Reason</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #getReason() - * @generated - * @ordered - */ - protected static final String REASON_EDEFAULT = null; - - /** - * The cached value of the '{@link #getReason() <em>Reason</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #getReason() - * @generated - * @ordered - */ - protected String reason = REASON_EDEFAULT; - - /** - * The cached value of the '{@link #getTestClasses() <em>Test Class</em>}' reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #getTestClasses() - * @generated - * @ordered - */ - protected EList<org.eclipse.uml2.uml.Class> testClasses; - - /** - * The cached value of the '{@link #getEditParts() <em>Edit Part</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #getEditParts() - * @generated - * @ordered - */ - protected EList<EditPartSpec> editParts; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - protected ForbiddenEditPartPermutationImpl() { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return ExceptionsPackage.Literals.FORBIDDEN_EDIT_PART_PERMUTATION; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EList<EditPartSpec> getEditParts() { - if (editParts == null) { - editParts = new EObjectContainmentEList<EditPartSpec>(EditPartSpec.class, this, ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION__EDIT_PART); - } - return editParts; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EditPartSpec createEditPart(EClass eClass) { - EditPartSpec newEditPart = (EditPartSpec) create(eClass); - getEditParts().add(newEditPart); - return newEditPart; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public ForbiddenReasonKind getReasonKind() { - return reasonKind; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public void setReasonKind(ForbiddenReasonKind newReasonKind) { - ForbiddenReasonKind oldReasonKind = reasonKind; - reasonKind = newReasonKind == null ? REASON_KIND_EDEFAULT : newReasonKind; - if (eNotificationRequired()) { - eNotify(new ENotificationImpl(this, Notification.SET, ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION__REASON_KIND, oldReasonKind, reasonKind)); - } - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public String getReason() { - return reason; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public void setReason(String newReason) { - String oldReason = reason; - reason = newReason; - if (eNotificationRequired()) { - eNotify(new ENotificationImpl(this, Notification.SET, ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION__REASON, oldReason, reason)); - } - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EList<org.eclipse.uml2.uml.Class> getTestClasses() { - if (testClasses == null) { - testClasses = new EObjectResolvingEList<org.eclipse.uml2.uml.Class>(org.eclipse.uml2.uml.Class.class, this, ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION__TEST_CLASS); - } - return testClasses; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public org.eclipse.uml2.uml.Class getTestClass(String name) { - return getTestClass(name, false, null); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public org.eclipse.uml2.uml.Class getTestClass(String name, boolean ignoreCase, EClass eClass) { - testClassLoop: for (org.eclipse.uml2.uml.Class testClass : getTestClasses()) { - if (eClass != null && !eClass.isInstance(testClass)) { - continue testClassLoop; - } - if (name != null && !(ignoreCase ? name.equalsIgnoreCase(testClass.getName()) : name.equals(testClass.getName()))) { - continue testClassLoop; - } - return testClass; - } - return null; - } - - /** - * The cached validation expression for the '{@link #test_classes(org.eclipse.emf.common.util.DiagnosticChain, java.util.Map) <em>Test classes</em>}' invariant operation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #test_classes(org.eclipse.emf.common.util.DiagnosticChain, java.util.Map) - * @generated - * @ordered - */ - protected static final String TEST_CLASSES_DIAGNOSTIC_CHAIN_MAP__EEXPRESSION = "testClass->forAll(conformsTo(_'org.eclipse.papyrus.uml.diagram.tests'::AbstractPapyrusTestCase.oclAsType(UML::Type)))"; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public boolean test_classes(DiagnosticChain diagnostics, Map<Object, Object> context) { - return ExceptionsValidator.validate(ExceptionsPackage.Literals.FORBIDDEN_EDIT_PART_PERMUTATION, - this, - diagnostics, - context, - "http://www.eclipse.org/emf/2002/Ecore/OCL", - ExceptionsPackage.Literals.FORBIDDEN_EDIT_PART_PERMUTATION___TEST_CLASSES__DIAGNOSTICCHAIN_MAP, - TEST_CLASSES_DIAGNOSTIC_CHAIN_MAP__EEXPRESSION, - Diagnostic.ERROR, - ExceptionsValidator.DIAGNOSTIC_SOURCE, - ExceptionsValidator.FORBIDDEN_EDIT_PART_PERMUTATION__TEST_CLASSES); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public boolean validate(EList<InstanceSpecification> editPart, org.eclipse.uml2.uml.Class testClass, DiagnosticChain diagnostics) { - return ForbiddenEditPartPermutationOperations.validate(this, editPart, testClass, diagnostics); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { - switch (featureID) { - case ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION__EDIT_PART: - return ((InternalEList<?>) getEditParts()).basicRemove(otherEnd, 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 ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION__REASON_KIND: - return getReasonKind(); - case ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION__REASON: - return getReason(); - case ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION__TEST_CLASS: - return getTestClasses(); - case ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION__EDIT_PART: - return getEditParts(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION__REASON_KIND: - setReasonKind((ForbiddenReasonKind) newValue); - return; - case ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION__REASON: - setReason((String) newValue); - return; - case ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION__TEST_CLASS: - getTestClasses().clear(); - getTestClasses().addAll((Collection<? extends org.eclipse.uml2.uml.Class>) newValue); - return; - case ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION__EDIT_PART: - getEditParts().clear(); - getEditParts().addAll((Collection<? extends EditPartSpec>) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION__REASON_KIND: - setReasonKind(REASON_KIND_EDEFAULT); - return; - case ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION__REASON: - setReason(REASON_EDEFAULT); - return; - case ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION__TEST_CLASS: - getTestClasses().clear(); - return; - case ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION__EDIT_PART: - getEditParts().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION__REASON_KIND: - return reasonKind != REASON_KIND_EDEFAULT; - case ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION__REASON: - return REASON_EDEFAULT == null ? reason != null : !REASON_EDEFAULT.equals(reason); - case ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION__TEST_CLASS: - return testClasses != null && !testClasses.isEmpty(); - case ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION__EDIT_PART: - return editParts != null && !editParts.isEmpty(); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - @SuppressWarnings("unchecked") - public Object eInvoke(int operationID, EList<?> arguments) throws InvocationTargetException { - switch (operationID) { - case ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION___TEST_CLASSES__DIAGNOSTICCHAIN_MAP: - return test_classes((DiagnosticChain) arguments.get(0), (Map<Object, Object>) arguments.get(1)); - case ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION___VALIDATE__ELIST_CLASS_DIAGNOSTICCHAIN: - return validate((EList<InstanceSpecification>) arguments.get(0), (org.eclipse.uml2.uml.Class) arguments.get(1), (DiagnosticChain) arguments.get(2)); - } - return super.eInvoke(operationID, arguments); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) { - return super.toString(); - } - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (reasonKind: "); - result.append(reasonKind); - result.append(", reason: "); - result.append(reason); - result.append(')'); - return result.toString(); - } - -} // ForbiddenEditPartPermutationImpl diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/TestConstraintImpl.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/TestConstraintImpl.java deleted file mode 100644 index 3337d9b667c..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/TestConstraintImpl.java +++ /dev/null @@ -1,357 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions.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.DiagnosticChain; -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.util.EcoreUtil; - -import org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage; -import org.eclipse.papyrus.tests.framework.exceptions.TestConstraint; -import org.eclipse.papyrus.tests.framework.exceptions.TestExceptions; - -import org.eclipse.papyrus.tests.framework.internal.exceptions.operations.TestConstraintOperations; - -import org.eclipse.uml2.uml.InstanceSpecification; - -/** - * <!-- begin-user-doc --> - * An implementation of the model object '<em><b>Test Constraint</b></em>'. - * <!-- end-user-doc --> - * <p> - * The following features are implemented: - * </p> - * <ul> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.impl.TestConstraintImpl#getContainer <em>Container</em>}</li> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.impl.TestConstraintImpl#isOmitOnFailure <em>Omit On Failure</em>}</li> - * </ul> - * - * @generated - */ -public abstract class TestConstraintImpl extends TestExceptionsObject implements TestConstraint { - /** - * The default value of the '{@link #isOmitOnFailure() <em>Omit On Failure</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #isOmitOnFailure() - * @generated - * @ordered - */ - protected static final boolean OMIT_ON_FAILURE_EDEFAULT = false; - /** - * The flag representing the value of the '{@link #isOmitOnFailure() <em>Omit On Failure</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #isOmitOnFailure() - * @generated - * @ordered - */ - protected static final int OMIT_ON_FAILURE_EFLAG = 1 << 0; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - protected TestConstraintImpl() { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return ExceptionsPackage.Literals.TEST_CONSTRAINT; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public TestExceptions getContainer() { - if (eContainerFeatureID() != ExceptionsPackage.TEST_CONSTRAINT__CONTAINER) { - return null; - } - return (TestExceptions) eInternalContainer(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public NotificationChain basicSetContainer(TestExceptions newContainer, NotificationChain msgs) { - msgs = eBasicSetContainer((InternalEObject) newContainer, ExceptionsPackage.TEST_CONSTRAINT__CONTAINER, msgs); - return msgs; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public void setContainer(TestExceptions newContainer) { - if (newContainer != eInternalContainer() || (eContainerFeatureID() != ExceptionsPackage.TEST_CONSTRAINT__CONTAINER && newContainer != null)) { - if (EcoreUtil.isAncestor(this, newContainer)) { - throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); - } - NotificationChain msgs = null; - if (eInternalContainer() != null) { - msgs = eBasicRemoveFromContainer(msgs); - } - if (newContainer != null) { - msgs = ((InternalEObject) newContainer).eInverseAdd(this, ExceptionsPackage.TEST_EXCEPTIONS__CONSTRAINT, TestExceptions.class, msgs); - } - msgs = basicSetContainer(newContainer, msgs); - if (msgs != null) { - msgs.dispatch(); - } - } else if (eNotificationRequired()) { - eNotify(new ENotificationImpl(this, Notification.SET, ExceptionsPackage.TEST_CONSTRAINT__CONTAINER, newContainer, newContainer)); - } - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public boolean isOmitOnFailure() { - return (eFlags & OMIT_ON_FAILURE_EFLAG) != 0; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public void setOmitOnFailure(boolean newOmitOnFailure) { - boolean oldOmitOnFailure = (eFlags & OMIT_ON_FAILURE_EFLAG) != 0; - if (newOmitOnFailure) { - eFlags |= OMIT_ON_FAILURE_EFLAG; - } else { - eFlags &= ~OMIT_ON_FAILURE_EFLAG; - } - if (eNotificationRequired()) { - eNotify(new ENotificationImpl(this, Notification.SET, ExceptionsPackage.TEST_CONSTRAINT__OMIT_ON_FAILURE, oldOmitOnFailure, newOmitOnFailure)); - } - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public boolean validate(EList<InstanceSpecification> editPart, org.eclipse.uml2.uml.Class testClass, DiagnosticChain diagnostics) { - return TestConstraintOperations.validate(this, editPart, testClass, diagnostics); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { - switch (featureID) { - case ExceptionsPackage.TEST_CONSTRAINT__CONTAINER: - if (eInternalContainer() != null) { - msgs = eBasicRemoveFromContainer(msgs); - } - return basicSetContainer((TestExceptions) otherEnd, msgs); - } - return super.eInverseAdd(otherEnd, featureID, msgs); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { - switch (featureID) { - case ExceptionsPackage.TEST_CONSTRAINT__CONTAINER: - return basicSetContainer(null, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { - switch (eContainerFeatureID()) { - case ExceptionsPackage.TEST_CONSTRAINT__CONTAINER: - return eInternalContainer().eInverseRemove(this, ExceptionsPackage.TEST_EXCEPTIONS__CONSTRAINT, TestExceptions.class, msgs); - } - return super.eBasicRemoveFromContainerFeature(msgs); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case ExceptionsPackage.TEST_CONSTRAINT__CONTAINER: - return getContainer(); - case ExceptionsPackage.TEST_CONSTRAINT__OMIT_ON_FAILURE: - return isOmitOnFailure(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case ExceptionsPackage.TEST_CONSTRAINT__CONTAINER: - setContainer((TestExceptions) newValue); - return; - case ExceptionsPackage.TEST_CONSTRAINT__OMIT_ON_FAILURE: - setOmitOnFailure((Boolean) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case ExceptionsPackage.TEST_CONSTRAINT__CONTAINER: - setContainer((TestExceptions) null); - return; - case ExceptionsPackage.TEST_CONSTRAINT__OMIT_ON_FAILURE: - setOmitOnFailure(OMIT_ON_FAILURE_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case ExceptionsPackage.TEST_CONSTRAINT__CONTAINER: - return getContainer() != null; - case ExceptionsPackage.TEST_CONSTRAINT__OMIT_ON_FAILURE: - return ((eFlags & OMIT_ON_FAILURE_EFLAG) != 0) != OMIT_ON_FAILURE_EDEFAULT; - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - @SuppressWarnings("unchecked") - public Object eInvoke(int operationID, EList<?> arguments) throws InvocationTargetException { - switch (operationID) { - case ExceptionsPackage.TEST_CONSTRAINT___VALIDATE__ELIST_CLASS_DIAGNOSTICCHAIN: - return validate((EList<InstanceSpecification>) arguments.get(0), (org.eclipse.uml2.uml.Class) arguments.get(1), (DiagnosticChain) arguments.get(2)); - } - return super.eInvoke(operationID, arguments); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) { - return super.toString(); - } - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (omitOnFailure: "); - result.append((eFlags & OMIT_ON_FAILURE_EFLAG) != 0); - 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); - } - -} // TestConstraintImpl diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/TestExceptionsImpl.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/TestExceptionsImpl.java deleted file mode 100644 index 8bb157c1c2b..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/impl/TestExceptionsImpl.java +++ /dev/null @@ -1,244 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions.impl; - -import java.lang.reflect.InvocationTargetException; -import java.util.Collection; - -import org.eclipse.emf.common.notify.NotificationChain; - -import org.eclipse.emf.common.util.DiagnosticChain; -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.util.EObjectContainmentWithInverseEList; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.ecore.util.InternalEList; - -import org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage; -import org.eclipse.papyrus.tests.framework.exceptions.TestConstraint; -import org.eclipse.papyrus.tests.framework.exceptions.TestExceptions; -import org.eclipse.papyrus.tests.framework.internal.exceptions.operations.TestExceptionsOperations; -import org.eclipse.uml2.uml.InstanceSpecification; - -/** - * <!-- begin-user-doc --> - * An implementation of the model object '<em><b>Test Exceptions</b></em>'. - * <!-- end-user-doc --> - * <p> - * The following features are implemented: - * </p> - * <ul> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.impl.TestExceptionsImpl#getConstraints <em>Constraint</em>}</li> - * </ul> - * - * @generated - */ -public class TestExceptionsImpl extends TestExceptionsObject implements TestExceptions { - /** - * The cached value of the '{@link #getConstraints() <em>Constraint</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see #getConstraints() - * @generated - * @ordered - */ - protected EList<TestConstraint> constraints; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - protected TestExceptionsImpl() { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return ExceptionsPackage.Literals.TEST_EXCEPTIONS; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public EList<TestConstraint> getConstraints() { - if (constraints == null) { - constraints = new EObjectContainmentWithInverseEList<TestConstraint>(TestConstraint.class, this, ExceptionsPackage.TEST_EXCEPTIONS__CONSTRAINT, ExceptionsPackage.TEST_CONSTRAINT__CONTAINER); - } - return constraints; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public TestConstraint createConstraint(EClass eClass) { - TestConstraint newConstraint = (TestConstraint) create(eClass); - getConstraints().add(newConstraint); - return newConstraint; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public boolean validate(EList<InstanceSpecification> editPart, org.eclipse.uml2.uml.Class testClass, DiagnosticChain diagnostics) { - return TestExceptionsOperations.validate(this, editPart, testClass, diagnostics); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { - switch (featureID) { - case ExceptionsPackage.TEST_EXCEPTIONS__CONSTRAINT: - return ((InternalEList<InternalEObject>) (InternalEList<?>) getConstraints()).basicAdd(otherEnd, msgs); - } - return super.eInverseAdd(otherEnd, featureID, msgs); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { - switch (featureID) { - case ExceptionsPackage.TEST_EXCEPTIONS__CONSTRAINT: - return ((InternalEList<?>) getConstraints()).basicRemove(otherEnd, 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 ExceptionsPackage.TEST_EXCEPTIONS__CONSTRAINT: - return getConstraints(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case ExceptionsPackage.TEST_EXCEPTIONS__CONSTRAINT: - getConstraints().clear(); - getConstraints().addAll((Collection<? extends TestConstraint>) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case ExceptionsPackage.TEST_EXCEPTIONS__CONSTRAINT: - getConstraints().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case ExceptionsPackage.TEST_EXCEPTIONS__CONSTRAINT: - return constraints != null && !constraints.isEmpty(); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - @SuppressWarnings("unchecked") - public Object eInvoke(int operationID, EList<?> arguments) throws InvocationTargetException { - switch (operationID) { - case ExceptionsPackage.TEST_EXCEPTIONS___VALIDATE__ELIST_CLASS_DIAGNOSTICCHAIN: - return validate((EList<InstanceSpecification>) arguments.get(0), (org.eclipse.uml2.uml.Class) arguments.get(1), (DiagnosticChain) arguments.get(2)); - } - return super.eInvoke(operationID, arguments); - } - - /** - * 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); - } - -} // TestExceptionsImpl diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/util/ExceptionsAdapterFactory.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/util/ExceptionsAdapterFactory.java deleted file mode 100644 index 887711439fa..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/util/ExceptionsAdapterFactory.java +++ /dev/null @@ -1,278 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions.util; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notifier; - -import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.papyrus.tests.framework.exceptions.*; - -/** - * <!-- begin-user-doc --> - * The <b>Adapter Factory</b> for the model. - * It provides an adapter <code>createXXX</code> method for each class of the model. - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage - * @generated - */ -public class ExceptionsAdapterFactory extends AdapterFactoryImpl { - /** - * The cached model package. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - protected static ExceptionsPackage modelPackage; - - /** - * Creates an instance of the adapter factory. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public ExceptionsAdapterFactory() { - if (modelPackage == null) { - modelPackage = ExceptionsPackage.eINSTANCE; - } - } - - /** - * Returns whether this factory is applicable for the type of the object. - * <!-- begin-user-doc --> - * This implementation returns <code>true</code> if the object is either the model's package or is an instance object of the model. - * <!-- end-user-doc --> - * - * @return whether this factory is applicable for the type of the object. - * @generated - */ - @Override - public boolean isFactoryForType(Object object) { - if (object == modelPackage) { - return true; - } - if (object instanceof EObject) { - return ((EObject) object).eClass().getEPackage() == modelPackage; - } - return false; - } - - /** - * The switch that delegates to the <code>createXXX</code> methods. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - protected ExceptionsSwitch<Adapter> modelSwitch = new ExceptionsSwitch<Adapter>() { - @Override - public Adapter caseForbiddenEditPartPermutation(ForbiddenEditPartPermutation object) { - return createForbiddenEditPartPermutationAdapter(); - } - - @Override - public Adapter caseTestConstraint(TestConstraint object) { - return createTestConstraintAdapter(); - } - - @Override - public Adapter caseTestExceptions(TestExceptions object) { - return createTestExceptionsAdapter(); - } - - @Override - public Adapter caseEditPartSpec(EditPartSpec object) { - return createEditPartSpecAdapter(); - } - - @Override - public Adapter caseCompositeEditPartSpec(CompositeEditPartSpec object) { - return createCompositeEditPartSpecAdapter(); - } - - @Override - public Adapter caseEditPartRef(EditPartRef object) { - return createEditPartRefAdapter(); - } - - @Override - public Adapter caseAnyEditPart(AnyEditPart object) { - return createAnyEditPartAdapter(); - } - - @Override - public Adapter caseForbiddenEditPart(ForbiddenEditPart object) { - return createForbiddenEditPartAdapter(); - } - - @Override - public Adapter defaultCase(EObject object) { - return createEObjectAdapter(); - } - }; - - /** - * Creates an adapter for the <code>target</code>. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param target - * the object to adapt. - * @return the adapter for the <code>target</code>. - * @generated - */ - @Override - public Adapter createAdapter(Notifier target) { - return modelSwitch.doSwitch((EObject) target); - } - - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPartPermutation <em>Forbidden Edit Part Permutation</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.tests.framework.exceptions.ForbiddenEditPartPermutation - * @generated - */ - public Adapter createForbiddenEditPartPermutationAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.papyrus.tests.framework.exceptions.TestConstraint <em>Test Constraint</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.tests.framework.exceptions.TestConstraint - * @generated - */ - public Adapter createTestConstraintAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.papyrus.tests.framework.exceptions.TestExceptions <em>Test Exceptions</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.tests.framework.exceptions.TestExceptions - * @generated - */ - public Adapter createTestExceptionsAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec <em>Edit Part Spec</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.tests.framework.exceptions.EditPartSpec - * @generated - */ - public Adapter createEditPartSpecAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.papyrus.tests.framework.exceptions.CompositeEditPartSpec <em>Composite Edit Part Spec</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.tests.framework.exceptions.CompositeEditPartSpec - * @generated - */ - public Adapter createCompositeEditPartSpecAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.papyrus.tests.framework.exceptions.EditPartRef <em>Edit Part Ref</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.tests.framework.exceptions.EditPartRef - * @generated - */ - public Adapter createEditPartRefAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.papyrus.tests.framework.exceptions.AnyEditPart <em>Any Edit Part</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.tests.framework.exceptions.AnyEditPart - * @generated - */ - public Adapter createAnyEditPartAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPart <em>Forbidden Edit Part</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.tests.framework.exceptions.ForbiddenEditPart - * @generated - */ - public Adapter createForbiddenEditPartAdapter() { - return null; - } - - /** - * Creates a new adapter for the default case. - * <!-- begin-user-doc --> - * This default implementation returns null. - * <!-- end-user-doc --> - * - * @return the new adapter. - * @generated - */ - public Adapter createEObjectAdapter() { - return null; - } - -} // ExceptionsAdapterFactory diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/util/ExceptionsResourceFactoryImpl.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/util/ExceptionsResourceFactoryImpl.java deleted file mode 100644 index 0887c0f8311..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/util/ExceptionsResourceFactoryImpl.java +++ /dev/null @@ -1,55 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions.util; - -import org.eclipse.emf.common.util.URI; - -import org.eclipse.emf.ecore.resource.Resource; - -import org.eclipse.emf.ecore.resource.impl.ResourceFactoryImpl; - -import org.eclipse.emf.ecore.xmi.XMLResource; - -/** - * <!-- begin-user-doc --> - * The <b>Resource Factory</b> associated with the package. - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.util.ExceptionsResourceImpl - * @generated - */ -public class ExceptionsResourceFactoryImpl extends ResourceFactoryImpl { - /** - * Creates an instance of the resource factory. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public ExceptionsResourceFactoryImpl() { - super(); - } - - /** - * Creates an instance of the resource. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public Resource createResource(URI uri) { - XMLResource result = new ExceptionsResourceImpl(uri); - return result; - } - -} // ExceptionsResourceFactoryImpl diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/util/ExceptionsResourceImpl.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/util/ExceptionsResourceImpl.java deleted file mode 100644 index f0b5059d782..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/util/ExceptionsResourceImpl.java +++ /dev/null @@ -1,40 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions.util; - -import org.eclipse.emf.common.util.URI; - -import org.eclipse.emf.ecore.xmi.impl.XMIResourceImpl; - -/** - * <!-- begin-user-doc --> - * The <b>Resource </b> associated with the package. - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.util.ExceptionsResourceFactoryImpl - * @generated - */ -public class ExceptionsResourceImpl extends XMIResourceImpl { - /** - * Creates an instance of the resource. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param uri - * the URI of the new resource. - * @generated - */ - public ExceptionsResourceImpl(URI uri) { - super(uri); - } - -} // ExceptionsResourceImpl diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/util/ExceptionsSwitch.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/util/ExceptionsSwitch.java deleted file mode 100644 index 6691f4c092a..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/util/ExceptionsSwitch.java +++ /dev/null @@ -1,322 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions.util; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; - -import org.eclipse.emf.ecore.util.Switch; - -import org.eclipse.papyrus.tests.framework.exceptions.*; - -/** - * <!-- begin-user-doc --> - * The <b>Switch</b> for the model's inheritance hierarchy. - * It supports the call {@link #doSwitch(EObject) doSwitch(object)} - * to invoke the <code>caseXXX</code> method for each class of the model, - * starting with the actual class of the object - * and proceeding up the inheritance hierarchy - * until a non-null result is returned, - * which is the result of the switch. - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage - * @generated - */ -public class ExceptionsSwitch<T> extends Switch<T> { - /** - * The cached model package - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - protected static ExceptionsPackage modelPackage; - - /** - * Creates an instance of the switch. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public ExceptionsSwitch() { - if (modelPackage == null) { - modelPackage = ExceptionsPackage.eINSTANCE; - } - } - - /** - * Checks whether this is a switch for the given package. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @param ePackage - * the package in question. - * @return whether this is a switch for the given package. - * @generated - */ - @Override - protected boolean isSwitchFor(EPackage ePackage) { - return ePackage == modelPackage; - } - - /** - * Calls <code>caseXXX</code> for each class of the model until one returns a non null result; it yields that result. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @return the first non-null result returned by a <code>caseXXX</code> call. - * @generated - */ - @Override - protected T doSwitch(int classifierID, EObject theEObject) { - switch (classifierID) { - case ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION: { - ForbiddenEditPartPermutation forbiddenEditPartPermutation = (ForbiddenEditPartPermutation) theEObject; - T result = caseForbiddenEditPartPermutation(forbiddenEditPartPermutation); - if (result == null) { - result = caseTestConstraint(forbiddenEditPartPermutation); - } - if (result == null) { - result = defaultCase(theEObject); - } - return result; - } - case ExceptionsPackage.TEST_CONSTRAINT: { - TestConstraint testConstraint = (TestConstraint) theEObject; - T result = caseTestConstraint(testConstraint); - if (result == null) { - result = defaultCase(theEObject); - } - return result; - } - case ExceptionsPackage.TEST_EXCEPTIONS: { - TestExceptions testExceptions = (TestExceptions) theEObject; - T result = caseTestExceptions(testExceptions); - if (result == null) { - result = defaultCase(theEObject); - } - return result; - } - case ExceptionsPackage.EDIT_PART_SPEC: { - EditPartSpec editPartSpec = (EditPartSpec) theEObject; - T result = caseEditPartSpec(editPartSpec); - if (result == null) { - result = defaultCase(theEObject); - } - return result; - } - case ExceptionsPackage.COMPOSITE_EDIT_PART_SPEC: { - CompositeEditPartSpec compositeEditPartSpec = (CompositeEditPartSpec) theEObject; - T result = caseCompositeEditPartSpec(compositeEditPartSpec); - if (result == null) { - result = caseEditPartSpec(compositeEditPartSpec); - } - if (result == null) { - result = defaultCase(theEObject); - } - return result; - } - case ExceptionsPackage.EDIT_PART_REF: { - EditPartRef editPartRef = (EditPartRef) theEObject; - T result = caseEditPartRef(editPartRef); - if (result == null) { - result = caseEditPartSpec(editPartRef); - } - if (result == null) { - result = defaultCase(theEObject); - } - return result; - } - case ExceptionsPackage.ANY_EDIT_PART: { - AnyEditPart anyEditPart = (AnyEditPart) theEObject; - T result = caseAnyEditPart(anyEditPart); - if (result == null) { - result = caseEditPartSpec(anyEditPart); - } - if (result == null) { - result = defaultCase(theEObject); - } - return result; - } - case ExceptionsPackage.FORBIDDEN_EDIT_PART: { - ForbiddenEditPart forbiddenEditPart = (ForbiddenEditPart) theEObject; - T result = caseForbiddenEditPart(forbiddenEditPart); - if (result == null) { - result = caseTestConstraint(forbiddenEditPart); - } - if (result == null) { - result = defaultCase(theEObject); - } - return result; - } - default: - return defaultCase(theEObject); - } - } - - /** - * Returns the result of interpreting the object as an instance of '<em>Forbidden Edit Part Permutation</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>Forbidden Edit Part Permutation</em>'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseForbiddenEditPartPermutation(ForbiddenEditPartPermutation object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of '<em>Test Constraint</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>Test Constraint</em>'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseTestConstraint(TestConstraint object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of '<em>Test Exceptions</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>Test Exceptions</em>'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseTestExceptions(TestExceptions object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of '<em>Edit Part Spec</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>Edit Part Spec</em>'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEditPartSpec(EditPartSpec object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of '<em>Composite Edit Part Spec</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>Composite Edit Part Spec</em>'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseCompositeEditPartSpec(CompositeEditPartSpec object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of '<em>Edit Part Ref</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>Edit Part Ref</em>'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEditPartRef(EditPartRef object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of '<em>Any Edit Part</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>Any Edit Part</em>'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseAnyEditPart(AnyEditPart object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of '<em>Forbidden Edit Part</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>Forbidden Edit Part</em>'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseForbiddenEditPart(ForbiddenEditPart object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of '<em>EObject</em>'. - * <!-- begin-user-doc --> - * This implementation returns null; - * returning a non-null result will terminate the switch, but this is the last case anyway. - * <!-- end-user-doc --> - * - * @param object - * 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 - */ - @Override - public T defaultCase(EObject object) { - return null; - } - -} // ExceptionsSwitch diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/util/ExceptionsValidator.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/util/ExceptionsValidator.java deleted file mode 100644 index a5b3cd70a24..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/exceptions/util/ExceptionsValidator.java +++ /dev/null @@ -1,307 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.exceptions.util; - -import java.util.Map; - -import org.eclipse.emf.common.util.DiagnosticChain; -import org.eclipse.emf.common.util.ResourceLocator; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EOperation; -import org.eclipse.emf.ecore.EPackage; - -import org.eclipse.emf.ecore.util.EObjectValidator; - -import org.eclipse.papyrus.tests.framework.exceptions.*; - -/** - * <!-- begin-user-doc --> - * The <b>Validator</b> for the model. - * <!-- end-user-doc --> - * - * @see org.eclipse.papyrus.tests.framework.exceptions.ExceptionsPackage - * @generated - */ -public class ExceptionsValidator extends EObjectValidator { - /** - * The cached model package - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public static final ExceptionsValidator INSTANCE = new ExceptionsValidator(); - - /** - * A constant for the {@link org.eclipse.emf.common.util.Diagnostic#getSource() source} of diagnostic {@link org.eclipse.emf.common.util.Diagnostic#getCode() codes} from this package. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @see org.eclipse.emf.common.util.Diagnostic#getSource() - * @see org.eclipse.emf.common.util.Diagnostic#getCode() - * @generated - */ - public static final String DIAGNOSTIC_SOURCE = "org.eclipse.papyrus.tests.framework.exceptions"; - - /** - * The {@link org.eclipse.emf.common.util.Diagnostic#getCode() code} for constraint 'Test classes' of 'Forbidden Edit Part Permutation'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public static final int FORBIDDEN_EDIT_PART_PERMUTATION__TEST_CLASSES = 1; - - /** - * A constant with a fixed name that can be used as the base value for additional hand written constants. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - private static final int GENERATED_DIAGNOSTIC_CODE_COUNT = 1; - - /** - * A constant with a fixed name that can be used as the base value for additional hand written constants in a derived class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - protected static final int DIAGNOSTIC_CODE_COUNT = GENERATED_DIAGNOSTIC_CODE_COUNT; - - /** - * Delegates evaluation of the given invariant expression against the object in the given context. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public static boolean validate(EClass eClass, EObject eObject, DiagnosticChain diagnostics, Map<Object, Object> context, String validationDelegate, EOperation invariant, String expression, int severity, String source, int code) { - return EObjectValidator.validate(eClass, eObject, diagnostics, context, validationDelegate, invariant, expression, severity, source, code); - } - - /** - * Creates an instance of the switch. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public ExceptionsValidator() { - super(); - } - - /** - * Returns the package of this validator switch. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - protected EPackage getEPackage() { - return ExceptionsPackage.eINSTANCE; - } - - /** - * Calls <code>validateXXX</code> for the corresponding classifier of the model. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - protected boolean validate(int classifierID, Object value, DiagnosticChain diagnostics, Map<Object, Object> context) { - switch (classifierID) { - case ExceptionsPackage.FORBIDDEN_EDIT_PART_PERMUTATION: - return validateForbiddenEditPartPermutation((ForbiddenEditPartPermutation) value, diagnostics, context); - case ExceptionsPackage.TEST_CONSTRAINT: - return validateTestConstraint((TestConstraint) value, diagnostics, context); - case ExceptionsPackage.TEST_EXCEPTIONS: - return validateTestExceptions((TestExceptions) value, diagnostics, context); - case ExceptionsPackage.EDIT_PART_SPEC: - return validateEditPartSpec((EditPartSpec) value, diagnostics, context); - case ExceptionsPackage.COMPOSITE_EDIT_PART_SPEC: - return validateCompositeEditPartSpec((CompositeEditPartSpec) value, diagnostics, context); - case ExceptionsPackage.EDIT_PART_REF: - return validateEditPartRef((EditPartRef) value, diagnostics, context); - case ExceptionsPackage.ANY_EDIT_PART: - return validateAnyEditPart((AnyEditPart) value, diagnostics, context); - case ExceptionsPackage.FORBIDDEN_EDIT_PART: - return validateForbiddenEditPart((ForbiddenEditPart) value, diagnostics, context); - case ExceptionsPackage.FORBIDDEN_REASON_KIND: - return validateForbiddenReasonKind((ForbiddenReasonKind) value, diagnostics, context); - case ExceptionsPackage.OPERATOR_KIND: - return validateOperatorKind((OperatorKind) value, diagnostics, context); - default: - return true; - } - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public boolean validateForbiddenEditPartPermutation(ForbiddenEditPartPermutation forbiddenEditPartPermutation, DiagnosticChain diagnostics, Map<Object, Object> context) { - if (!validate_NoCircularContainment(forbiddenEditPartPermutation, diagnostics, context)) { - return false; - } - boolean result = validate_EveryMultiplicityConforms(forbiddenEditPartPermutation, diagnostics, context); - if (result || diagnostics != null) { - result &= validate_EveryDataValueConforms(forbiddenEditPartPermutation, diagnostics, context); - } - if (result || diagnostics != null) { - result &= validate_EveryReferenceIsContained(forbiddenEditPartPermutation, diagnostics, context); - } - if (result || diagnostics != null) { - result &= validate_EveryBidirectionalReferenceIsPaired(forbiddenEditPartPermutation, diagnostics, context); - } - if (result || diagnostics != null) { - result &= validate_EveryProxyResolves(forbiddenEditPartPermutation, diagnostics, context); - } - if (result || diagnostics != null) { - result &= validate_UniqueID(forbiddenEditPartPermutation, diagnostics, context); - } - if (result || diagnostics != null) { - result &= validate_EveryKeyUnique(forbiddenEditPartPermutation, diagnostics, context); - } - if (result || diagnostics != null) { - result &= validate_EveryMapEntryUnique(forbiddenEditPartPermutation, diagnostics, context); - } - if (result || diagnostics != null) { - result &= validateForbiddenEditPartPermutation_test_classes(forbiddenEditPartPermutation, diagnostics, context); - } - return result; - } - - /** - * Validates the test_classes constraint of '<em>Forbidden Edit Part Permutation</em>'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public boolean validateForbiddenEditPartPermutation_test_classes(ForbiddenEditPartPermutation forbiddenEditPartPermutation, DiagnosticChain diagnostics, Map<Object, Object> context) { - return forbiddenEditPartPermutation.test_classes(diagnostics, context); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public boolean validateTestConstraint(TestConstraint testConstraint, DiagnosticChain diagnostics, Map<Object, Object> context) { - return validate_EveryDefaultConstraint(testConstraint, diagnostics, context); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public boolean validateTestExceptions(TestExceptions testExceptions, DiagnosticChain diagnostics, Map<Object, Object> context) { - return validate_EveryDefaultConstraint(testExceptions, diagnostics, context); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public boolean validateEditPartSpec(EditPartSpec editPartSpec, DiagnosticChain diagnostics, Map<Object, Object> context) { - return validate_EveryDefaultConstraint(editPartSpec, diagnostics, context); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public boolean validateCompositeEditPartSpec(CompositeEditPartSpec compositeEditPartSpec, DiagnosticChain diagnostics, Map<Object, Object> context) { - return validate_EveryDefaultConstraint(compositeEditPartSpec, diagnostics, context); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public boolean validateEditPartRef(EditPartRef editPartRef, DiagnosticChain diagnostics, Map<Object, Object> context) { - return validate_EveryDefaultConstraint(editPartRef, diagnostics, context); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public boolean validateAnyEditPart(AnyEditPart anyEditPart, DiagnosticChain diagnostics, Map<Object, Object> context) { - return validate_EveryDefaultConstraint(anyEditPart, diagnostics, context); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public boolean validateForbiddenEditPart(ForbiddenEditPart forbiddenEditPart, DiagnosticChain diagnostics, Map<Object, Object> context) { - return validate_EveryDefaultConstraint(forbiddenEditPart, diagnostics, context); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public boolean validateForbiddenReasonKind(ForbiddenReasonKind forbiddenReasonKind, DiagnosticChain diagnostics, Map<Object, Object> context) { - return true; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - public boolean validateOperatorKind(OperatorKind operatorKind, DiagnosticChain diagnostics, Map<Object, Object> context) { - return true; - } - - /** - * Returns the resource locator that will be used to fetch messages for this validator's diagnostics. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - // TODO - // Specialize this to return a resource locator for messages specific to this validator. - // Ensure that you remove @generated or mark it @generated NOT - return super.getResourceLocator(); - } - -} // ExceptionsValidator diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/internal/exceptions/operations/AnyEditPartOperations.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/internal/exceptions/operations/AnyEditPartOperations.java deleted file mode 100644 index 4d842607a1c..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/internal/exceptions/operations/AnyEditPartOperations.java +++ /dev/null @@ -1,52 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.internal.exceptions.operations; - -import org.eclipse.papyrus.tests.framework.exceptions.AnyEditPart; -import org.eclipse.uml2.uml.InstanceSpecification; - -/** - * <!-- begin-user-doc --> - * A static utility class that provides operations related to '<em><b>Any Edit Part</b></em>' model objects. - * <!-- end-user-doc --> - * - * <p> - * The following operations are supported: - * </p> - * <ul> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.AnyEditPart#matches(org.eclipse.uml2.uml.InstanceSpecification) <em>Matches</em>}</li> - * </ul> - * - * @generated - */ -public class AnyEditPartOperations extends EditPartSpecOperations { - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - protected AnyEditPartOperations() { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated NOT - */ - public static boolean matches(AnyEditPart anyEditPart, InstanceSpecification editPart) { - return true; - } - -} // AnyEditPartOperations diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/internal/exceptions/operations/CompositeEditPartSpecOperations.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/internal/exceptions/operations/CompositeEditPartSpecOperations.java deleted file mode 100644 index 024cdb800e2..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/internal/exceptions/operations/CompositeEditPartSpecOperations.java +++ /dev/null @@ -1,80 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.internal.exceptions.operations; - -import java.util.Iterator; - -import org.eclipse.papyrus.tests.framework.exceptions.CompositeEditPartSpec; -import org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec; -import org.eclipse.uml2.uml.InstanceSpecification; - -/** - * <!-- begin-user-doc --> - * A static utility class that provides operations related to '<em><b>Composite Edit Part Spec</b></em>' model objects. - * <!-- end-user-doc --> - * - * <p> - * The following operations are supported: - * </p> - * <ul> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.CompositeEditPartSpec#matches(org.eclipse.uml2.uml.InstanceSpecification) <em>Matches</em>}</li> - * </ul> - * - * @generated - */ -public class CompositeEditPartSpecOperations extends EditPartSpecOperations { - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - protected CompositeEditPartSpecOperations() { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated NOT - */ - public static boolean matches(CompositeEditPartSpec compositeEditPartSpec, InstanceSpecification editPart) { - boolean result; - - switch (compositeEditPartSpec.getOperator()) { - case AND: - result = true; - for (Iterator<EditPartSpec> iter = compositeEditPartSpec.getOperands().iterator(); result && iter.hasNext();) { - result = iter.next().matches(editPart); - } - break; - case OR: - result = false; - for (Iterator<EditPartSpec> iter = compositeEditPartSpec.getOperands().iterator(); !result && iter.hasNext();) { - result = iter.next().matches(editPart); - } - break; - case NOT: - result = true; - for (Iterator<EditPartSpec> iter = compositeEditPartSpec.getOperands().iterator(); result && iter.hasNext();) { - result = !iter.next().matches(editPart); - } - break; - default: - throw new IllegalArgumentException("unimplemented operator: " + compositeEditPartSpec.getOperator()); //$NON-NLS-1$ - } - - return result; - } - -} // CompositeEditPartSpecOperations diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/internal/exceptions/operations/EditPartRefOperations.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/internal/exceptions/operations/EditPartRefOperations.java deleted file mode 100644 index 705aebc4c2f..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/internal/exceptions/operations/EditPartRefOperations.java +++ /dev/null @@ -1,87 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.internal.exceptions.operations; - -import org.eclipse.papyrus.tests.framework.exceptions.EditPartRef; -import org.eclipse.uml2.uml.InstanceSpecification; -import org.eclipse.uml2.uml.NamedElement; -import org.eclipse.uml2.uml.Slot; - -import com.google.common.base.Function; -import com.google.common.base.Predicate; -import com.google.common.collect.Iterables; - -/** - * <!-- begin-user-doc --> - * A static utility class that provides operations related to '<em><b>Edit Part Ref</b></em>' model objects. - * <!-- end-user-doc --> - * - * <p> - * The following operations are supported: - * </p> - * <ul> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.EditPartRef#matches(org.eclipse.uml2.uml.InstanceSpecification) <em>Matches</em>}</li> - * </ul> - * - * @generated - */ -public class EditPartRefOperations extends EditPartSpecOperations { - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - protected EditPartRefOperations() { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated NOT - */ - public static boolean matches(EditPartRef editPartRef, InstanceSpecification editPart) { - String editPartClassName = getEditPartClassNameFunction().apply(editPart); - return (editPartClassName != null) && editPartClassName.equals(editPartRef.getEditPart().getEditPartClassName()); - } - - protected static Predicate<NamedElement> named(final String name) { - return new Predicate<NamedElement>() { - @Override - public boolean apply(NamedElement input) { - return name.equals(input.getName()); - } - }; - } - - protected static Predicate<Slot> slotDefinedBy(final String definingFeature) { - return new Predicate<Slot>() { - @Override - public boolean apply(Slot input) { - return (input.getDefiningFeature() != null) && definingFeature.equals(input.getDefiningFeature().getName()); - } - }; - } - - protected static Function<InstanceSpecification, String> getEditPartClassNameFunction() { - return new Function<InstanceSpecification, String>() { - @Override - public String apply(InstanceSpecification input) { - Slot classNameSlot = Iterables.find(input.getSlots(), slotDefinedBy("editPartClassName")); - return ((classNameSlot == null) || classNameSlot.getValues().isEmpty()) ? null : classNameSlot.getValues().get(0).stringValue(); - } - }; - } - -} // EditPartRefOperations diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/internal/exceptions/operations/EditPartSpecOperations.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/internal/exceptions/operations/EditPartSpecOperations.java deleted file mode 100644 index fea88723fef..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/internal/exceptions/operations/EditPartSpecOperations.java +++ /dev/null @@ -1,52 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.internal.exceptions.operations; - -import org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec; -import org.eclipse.uml2.uml.InstanceSpecification; - -/** - * <!-- begin-user-doc --> - * A static utility class that provides operations related to '<em><b>Edit Part Spec</b></em>' model objects. - * <!-- end-user-doc --> - * - * <p> - * The following operations are supported: - * </p> - * <ul> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec#matches(org.eclipse.uml2.uml.InstanceSpecification) <em>Matches</em>}</li> - * </ul> - * - * @generated - */ -public class EditPartSpecOperations { - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - protected EditPartSpecOperations() { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated NOT - */ - public static boolean matches(EditPartSpec editPartSpec, InstanceSpecification editPart) { - throw new UnsupportedOperationException("abstract operation"); //$NON-NLS-1$ - } - -} // EditPartSpecOperations diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/internal/exceptions/operations/ForbiddenEditPartOperations.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/internal/exceptions/operations/ForbiddenEditPartOperations.java deleted file mode 100644 index 182ba493878..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/internal/exceptions/operations/ForbiddenEditPartOperations.java +++ /dev/null @@ -1,68 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.internal.exceptions.operations; - -import java.util.Iterator; - -import org.eclipse.emf.common.util.DiagnosticChain; -import org.eclipse.emf.common.util.EList; -import org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPart; -import org.eclipse.uml2.uml.InstanceSpecification; - -/** - * <!-- begin-user-doc --> - * A static utility class that provides operations related to '<em><b>Forbidden Edit Part</b></em>' model objects. - * <!-- end-user-doc --> - * - * <p> - * The following operations are supported: - * </p> - * <ul> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPart#validate(org.eclipse.emf.common.util.EList, org.eclipse.uml2.uml.Class, org.eclipse.emf.common.util.DiagnosticChain) <em>Validate</em>}</li> - * </ul> - * - * @generated - */ -public class ForbiddenEditPartOperations extends TestConstraintOperations { - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - protected ForbiddenEditPartOperations() { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated NOT - */ - public static boolean validate(ForbiddenEditPart constraint, EList<InstanceSpecification> editPart, org.eclipse.uml2.uml.Class testClass, DiagnosticChain diagnostics) { - // Assume OK until proven otherwise - boolean result = true; - - // The constraint is satisfied if every edit part is not forbidden - for (Iterator<InstanceSpecification> iter = editPart.iterator(); result && iter.hasNext();) { - result = !constraint.getEditPart().matches(iter.next()); - } - - if (!result && (diagnostics != null)) { - diagnostics.add(createDiagnostic(constraint, constraint.getReasonKind(), constraint.getReason(), testClass, editPart)); - } - - return result; - } - -} // ForbiddenEditPartOperations diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/internal/exceptions/operations/ForbiddenEditPartPermutationOperations.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/internal/exceptions/operations/ForbiddenEditPartPermutationOperations.java deleted file mode 100644 index debbb8a0266..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/internal/exceptions/operations/ForbiddenEditPartPermutationOperations.java +++ /dev/null @@ -1,81 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.internal.exceptions.operations; - -import java.util.List; - -import org.eclipse.emf.common.util.DiagnosticChain; -import org.eclipse.emf.common.util.EList; -import org.eclipse.papyrus.tests.framework.exceptions.EditPartSpec; -import org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPartPermutation; -import org.eclipse.uml2.uml.InstanceSpecification; - -/** - * <!-- begin-user-doc --> - * A static utility class that provides operations related to '<em><b>Forbidden Edit Part Permutation</b></em>' model objects. - * <!-- end-user-doc --> - * - * <p> - * The following operations are supported: - * </p> - * <ul> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.ForbiddenEditPartPermutation#validate(org.eclipse.emf.common.util.EList, org.eclipse.uml2.uml.Class, org.eclipse.emf.common.util.DiagnosticChain) <em>Validate</em>}</li> - * </ul> - * - * @generated - */ -public class ForbiddenEditPartPermutationOperations extends TestConstraintOperations { - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - protected ForbiddenEditPartPermutationOperations() { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated NOT - */ - public static boolean validate(ForbiddenEditPartPermutation constraint, EList<InstanceSpecification> editPart, org.eclipse.uml2.uml.Class testClass, DiagnosticChain diagnostics) { - boolean result = true; // Assume satisfied until otherwise determined - - for (org.eclipse.uml2.uml.Class next : constraint.getTestClasses()) { - if (testClass.conformsTo(next)) { - // Eligible, so far. Check the edit-parts - List<EditPartSpec> constraintEditParts = constraint.getEditParts(); - if (editPart.size() == constraintEditParts.size()) { - // Assume the constraint is not satisfied - result = false; - - for (int i = 0; !result && (i < editPart.size()); i++) { - // The constraint is satisfied if any one of the edit parts is not forbidden in this permutation - result = !constraintEditParts.get(i).matches(editPart.get(i)); - } - - if (!result && (diagnostics != null)) { - diagnostics.add(createDiagnostic(constraint, constraint.getReasonKind(), constraint.getReason(), testClass, editPart)); - } - } - - break; - } - } - - return result; - } - -} // ForbiddenEditPartPermutationOperations diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/internal/exceptions/operations/TestConstraintOperations.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/internal/exceptions/operations/TestConstraintOperations.java deleted file mode 100644 index eb3f3aa7d2e..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/internal/exceptions/operations/TestConstraintOperations.java +++ /dev/null @@ -1,105 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.internal.exceptions.operations; - -import java.util.Map; - -import org.apache.log4j.Logger; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.DiagnosticChain; -import org.eclipse.emf.common.util.EList; -import org.eclipse.osgi.util.NLS; -import org.eclipse.papyrus.tests.framework.Activator; -import org.eclipse.papyrus.tests.framework.exceptions.ForbiddenReasonKind; -import org.eclipse.papyrus.tests.framework.exceptions.TestConstraint; -import org.eclipse.uml2.uml.Class; -import org.eclipse.uml2.uml.InstanceSpecification; - -import com.google.common.base.Joiner; -import com.google.common.collect.ImmutableMap; -import com.google.common.collect.Iterables; -import com.google.common.collect.Maps; - -/** - * <!-- begin-user-doc --> - * A static utility class that provides operations related to '<em><b>Test Constraint</b></em>' model objects. - * <!-- end-user-doc --> - * - * <p> - * The following operations are supported: - * </p> - * <ul> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.TestConstraint#validate(org.eclipse.emf.common.util.EList, org.eclipse.uml2.uml.Class, org.eclipse.emf.common.util.DiagnosticChain) <em>Validate</em>}</li> - * </ul> - * - * @generated - */ -public class TestConstraintOperations { - private static final String CLASSIFICATION_PACKAGE = "org.eclipse.papyrus.junit.framework.classification"; //$NON-NLS-1$ - - private static final Map<ForbiddenReasonKind, String> ANNOTATIONS = Maps.immutableEnumMap(ImmutableMap.of( - ForbiddenReasonKind.FAILING, CLASSIFICATION_PACKAGE + ".FailingTest", //$NON-NLS-1$ - ForbiddenReasonKind.INVALID, CLASSIFICATION_PACKAGE + ".InvalidTest", //$NON-NLS-1$ - ForbiddenReasonKind.UNIMPLEMENTED, CLASSIFICATION_PACKAGE + ".NotImplemented", //$NON-NLS-1$ - ForbiddenReasonKind.INTERACTIVE, CLASSIFICATION_PACKAGE + ".InteractiveTest")); //$NON-NLS-1$ - - private static Logger logger = Logger.getLogger(TestConstraintOperations.class); - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - protected TestConstraintOperations() { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated NOT - */ - public static boolean validate(TestConstraint testConstraint, EList<InstanceSpecification> editPart, org.eclipse.uml2.uml.Class testClass, DiagnosticChain diagnostics) { - throw new UnsupportedOperationException("abstract operation"); - } - - protected static Diagnostic createDiagnostic(TestConstraint constraint, ForbiddenReasonKind reasonKind, String reason, Class testClass, Iterable<? extends InstanceSpecification> editPart) { - String editPartNames = Joiner.on(", ").join(Iterables.transform(editPart, EditPartRefOperations.getEditPartClassNameFunction())); - String message = NLS.bind("{0} {1} {2} test case for {3}: {4}", new Object[] { - constraint.isOmitOnFailure() ? "Omitting" : "Annotating", - reasonKind.getLiteral(), - testClass == null ? "any" : testClass.getName(), - editPartNames, - reason - }); - logger.info(message); - - String annotationName; - switch (reasonKind) { - case FAILING: - case INVALID: - case UNIMPLEMENTED: - case INTERACTIVE: - annotationName = ANNOTATIONS.get(reasonKind); - break; - default: - throw new IllegalArgumentException("unsupported reason kind: " + reasonKind); //$NON-NLS-1$ - } - - int severity = constraint.isOmitOnFailure() ? Diagnostic.ERROR : Diagnostic.WARNING; - return new BasicDiagnostic(severity, Activator.PLUGIN_ID, 0, reason, new Object[] { annotationName }); - } - -} // TestConstraintOperations diff --git a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/internal/exceptions/operations/TestExceptionsOperations.java b/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/internal/exceptions/operations/TestExceptionsOperations.java deleted file mode 100644 index 5e4a666f3b1..00000000000 --- a/tests/framework/org.eclipse.papyrus.tests.framework/src-gen/org/eclipse/papyrus/tests/framework/internal/exceptions/operations/TestExceptionsOperations.java +++ /dev/null @@ -1,63 +0,0 @@ -/** - * Copyright (c) 2015 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 v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Christian W. Damus - Initial API and implementation - */ -package org.eclipse.papyrus.tests.framework.internal.exceptions.operations; - -import org.eclipse.emf.common.util.DiagnosticChain; -import org.eclipse.emf.common.util.EList; -import org.eclipse.papyrus.tests.framework.exceptions.TestConstraint; -import org.eclipse.papyrus.tests.framework.exceptions.TestExceptions; -import org.eclipse.uml2.uml.InstanceSpecification; - -import com.google.common.base.Predicate; -import com.google.common.collect.Iterables; - -/** - * <!-- begin-user-doc --> - * A static utility class that provides operations related to '<em><b>Test Exceptions</b></em>' model objects. - * <!-- end-user-doc --> - * - * <p> - * The following operations are supported: - * </p> - * <ul> - * <li>{@link org.eclipse.papyrus.tests.framework.exceptions.TestExceptions#validate(org.eclipse.emf.common.util.EList, org.eclipse.uml2.uml.Class, org.eclipse.emf.common.util.DiagnosticChain) <em>Validate</em>}</li> - * </ul> - * - * @generated - */ -public class TestExceptionsOperations { - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - protected TestExceptionsOperations() { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated NOT - */ - public static boolean validate(TestExceptions testExceptions, final EList<InstanceSpecification> editPart, final org.eclipse.uml2.uml.Class testClass, final DiagnosticChain diagnostics) { - return testExceptions.getConstraints().isEmpty() || Iterables.all(testExceptions.getConstraints(), new Predicate<TestConstraint>() { - @Override - public boolean apply(TestConstraint input) { - return input.validate(editPart, testClass, diagnostics); - } - }); - } - -} // TestExceptionsOperations |