diff options
10 files changed, 717 insertions, 5 deletions
diff --git a/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable/src/org/eclipse/papyrus/uml/nattable/utils/UMLTableUtils.java b/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable/src/org/eclipse/papyrus/uml/nattable/utils/UMLTableUtils.java index 9d609df834c..4323ef05494 100644 --- a/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable/src/org/eclipse/papyrus/uml/nattable/utils/UMLTableUtils.java +++ b/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable/src/org/eclipse/papyrus/uml/nattable/utils/UMLTableUtils.java @@ -35,6 +35,7 @@ import org.eclipse.papyrus.infra.nattable.utils.Constants; import org.eclipse.papyrus.infra.nattable.utils.CrossAxisWrapper; import org.eclipse.papyrus.uml.nattable.paste.StereotypeApplicationStructure; import org.eclipse.papyrus.uml.tools.utils.NamedElementUtil; +import org.eclipse.papyrus.uml.tools.utils.StereotypeUtil; import org.eclipse.uml2.uml.Element; import org.eclipse.uml2.uml.NamedElement; import org.eclipse.uml2.uml.Package; @@ -104,7 +105,9 @@ public class UMLTableUtils { final Iterator<Profile> appliedProfilesIterator = element.getNearestPackage().getAllAppliedProfiles().iterator(); while(appliedProfilesIterator.hasNext() && null == result){ final Profile appliedProfile = appliedProfilesIterator.next(); - final Iterator<Stereotype> stereotypesIterator = appliedProfile.getOwnedStereotypes().iterator(); + + // Bug 488082 : Loop on all stereotypes (check in sub packages) + final Iterator<Stereotype> stereotypesIterator = StereotypeUtil.getAllStereotypes(appliedProfile).iterator(); while(stereotypesIterator.hasNext() && null == result){ final Stereotype ownedStereotype = stereotypesIterator.next(); final Iterator<Property> propertiesIterator = ownedStereotype.getAllAttributes().iterator(); diff --git a/plugins/uml/tools/org.eclipse.papyrus.uml.tools.utils/src/org/eclipse/papyrus/uml/tools/utils/StereotypeUtil.java b/plugins/uml/tools/org.eclipse.papyrus.uml.tools.utils/src/org/eclipse/papyrus/uml/tools/utils/StereotypeUtil.java index 9565f5bdf0b..58ec171a394 100644 --- a/plugins/uml/tools/org.eclipse.papyrus.uml.tools.utils/src/org/eclipse/papyrus/uml/tools/utils/StereotypeUtil.java +++ b/plugins/uml/tools/org.eclipse.papyrus.uml.tools.utils/src/org/eclipse/papyrus/uml/tools/utils/StereotypeUtil.java @@ -9,6 +9,7 @@ * * Contributors: * Patrick Tessier (CEA LIST) Patrick.tessier@cea.fr - Initial API and implementation + * Nicolas FAUVERGUE (ALL4TEC) nicolas.fauvergue@all4tec.net - Bug 488082 * *****************************************************************************/ package org.eclipse.papyrus.uml.tools.utils; @@ -35,6 +36,9 @@ import org.eclipse.uml2.uml.EnumerationLiteral; import org.eclipse.uml2.uml.Extension; import org.eclipse.uml2.uml.Image; import org.eclipse.uml2.uml.NamedElement; +import org.eclipse.uml2.uml.Namespace; +import org.eclipse.uml2.uml.Package; +import org.eclipse.uml2.uml.Profile; import org.eclipse.uml2.uml.Property; import org.eclipse.uml2.uml.Stereotype; import org.eclipse.uml2.uml.util.UMLUtil; @@ -1003,4 +1007,44 @@ public class StereotypeUtil { } return name; } + + /** + * This allows to get all stereotypes of a profile (check in sub packages). + * + * @param profile the profile. + * @return The list of stereotypes corresponding to the profile. + */ + public static List<Stereotype> getAllStereotypes(final Profile profile){ + final List<Stereotype> stereotypes = new ArrayList<Stereotype>(profile.getOwnedStereotypes()); + stereotypes.addAll(getStereotypeInMembers(profile.getOwnedMembers())); + return stereotypes; + } + + /** + * This allows to get all stereotypes in sub packages. + * + * @param members The owned members of an element. + * @return The list of stereotypes in sub packages. + */ + protected static List<Stereotype> getStereotypeInMembers(final List<NamedElement> members){ + final List<Stereotype> stereotypes = new ArrayList<Stereotype>(); + + // Loop on members + final Iterator<NamedElement> membersIterator = members.iterator(); + while(membersIterator.hasNext()){ + NamedElement member = membersIterator.next(); + + // Get stereotypes in packages + if(member instanceof Package){ + stereotypes.addAll(((Package) member).getOwnedStereotypes()); + } + + // Loop recursively in members + if(member instanceof Namespace){ + stereotypes.addAll(getStereotypeInMembers(((Namespace) member).getOwnedMembers())); + } + } + + return stereotypes; + } } diff --git a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/resources/bugs/bug488082/488082.di b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/resources/bugs/bug488082/488082.di new file mode 100644 index 00000000000..bf9abab340f --- /dev/null +++ b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/resources/bugs/bug488082/488082.di @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="UTF-8"?> +<xmi:XMI xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI"/> diff --git a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/resources/bugs/bug488082/488082.notation b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/resources/bugs/bug488082/488082.notation new file mode 100644 index 00000000000..5683ca658d6 --- /dev/null +++ b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/resources/bugs/bug488082/488082.notation @@ -0,0 +1,33 @@ +<?xml version="1.0" encoding="UTF-8"?> +<nattable:Table xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:configuration="http://www.eclipse.org/papyrus/infra/viewpoints/configuration" xmlns:nattable="http://www.eclipse.org/papyrus/nattable/model" xmlns:nattableaxis="http://www.eclipse.org/papyrus/nattable/model/table/nattableaxis" xmlns:nattableaxisconfiguration="http://www.eclipse.org/papyrus/nattable/model/table/nattableaxisconfiguration" xmlns:nattableaxisprovider="http://www.eclipse.org/papyrus/nattable/model/table/nattableaxisprovider" xmlns:nattableconfiguration="http://www.eclipse.org/papyrus/nattable/model/nattableconfiguration" xmlns:uml="http://www.eclipse.org/uml2/5.0.0/UML" xsi:schemaLocation="http://www.eclipse.org/papyrus/nattable/model/table/nattableaxis http://www.eclipse.org/papyrus/nattable/model#//nattableaxis http://www.eclipse.org/papyrus/nattable/model/table/nattableaxisconfiguration http://www.eclipse.org/papyrus/nattable/model#//nattableaxisconfiguration http://www.eclipse.org/papyrus/nattable/model/table/nattableaxisprovider http://www.eclipse.org/papyrus/nattable/model#//nattableaxisprovider http://www.eclipse.org/papyrus/nattable/model/nattableconfiguration http://www.eclipse.org/papyrus/nattable/model#//nattableconfiguration" xmi:id="_6rKk8NlSEeWE_b6VdATlFQ" name="GenericTable0" currentRowAxisProvider="_6rKk8tlSEeWE_b6VdATlFQ" currentColumnAxisProvider="_6rKk8dlSEeWE_b6VdATlFQ"> + <context xmi:type="uml:Model" href="488082.uml#_jHhRQNlOEeWbEpm2b0WIXQ"/> + <owner xmi:type="uml:Model" href="488082.uml#_jHhRQNlOEeWbEpm2b0WIXQ"/> + <prototype xmi:type="configuration:PapyrusSyncTable" href="platform:/plugin/org.eclipse.papyrus.infra.viewpoints.policy/builtin/default.configuration#_7wNb2NxhEeOqHvRyiN87hA"/> + <tableConfiguration xmi:type="nattableconfiguration:TableConfiguration" href="platform:/plugin/org.eclipse.papyrus.uml.nattable.generic.config/configs/generic.nattableconfiguration#/"/> + <columnAxisProvidersHistory xmi:type="nattableaxisprovider:SlaveObjectAxisProvider" xmi:id="_6rKk8dlSEeWE_b6VdATlFQ" description="This axis provider provides available columns according to the rows of the table (features of the object displayed on the other axis)" name="UML Feature axis provider"> + <axis xmi:type="nattableaxis:FeatureIdAxis" xmi:id="_67WWAtlSEeWE_b6VdATlFQ" element="property_of_stereotype:/RootElement::Package1::Profile1::Stereotype1::Attribute1_1"> + <manager xmi:type="nattableaxisconfiguration:AxisManagerRepresentation" href="platform:/plugin/org.eclipse.papyrus.uml.nattable.generic.config/configs/generic.nattableconfiguration#//@columnHeaderAxisConfiguration/@axisManagers.1"/> + </axis> + <axis xmi:type="nattableaxis:FeatureIdAxis" xmi:id="_67WWA9lSEeWE_b6VdATlFQ" element="property_of_stereotype:/RootElement::Package1::Profile1::Stereotype1::Attribute1_2"> + <manager xmi:type="nattableaxisconfiguration:AxisManagerRepresentation" href="platform:/plugin/org.eclipse.papyrus.uml.nattable.generic.config/configs/generic.nattableconfiguration#//@columnHeaderAxisConfiguration/@axisManagers.1"/> + </axis> + <axis xmi:type="nattableaxis:FeatureIdAxis" xmi:id="_67WWAdlSEeWE_b6VdATlFQ" element="property_of_stereotype:/RootElement::Package1::Stereotype2::Attribute2_1"> + <manager xmi:type="nattableaxisconfiguration:AxisManagerRepresentation" href="platform:/plugin/org.eclipse.papyrus.uml.nattable.generic.config/configs/generic.nattableconfiguration#//@columnHeaderAxisConfiguration/@axisManagers.1"/> + </axis> + <axis xmi:type="nattableaxis:FeatureIdAxis" xmi:id="_67WWBNlSEeWE_b6VdATlFQ" element="property_of_stereotype:/RootElement::Package1::Stereotype2::Attribute2_2"> + <manager xmi:type="nattableaxisconfiguration:AxisManagerRepresentation" href="platform:/plugin/org.eclipse.papyrus.uml.nattable.generic.config/configs/generic.nattableconfiguration#//@columnHeaderAxisConfiguration/@axisManagers.1"/> + </axis> + <axis xmi:type="nattableaxis:FeatureIdAxis" xmi:id="_67WWANlSEeWE_b6VdATlFQ" element="property_of_stereotype:/RootElement::Package1::Package1_1::Stereotype3::Attribute3_1"> + <manager xmi:type="nattableaxisconfiguration:AxisManagerRepresentation" href="platform:/plugin/org.eclipse.papyrus.uml.nattable.generic.config/configs/generic.nattableconfiguration#//@columnHeaderAxisConfiguration/@axisManagers.1"/> + </axis> + <axis xmi:type="nattableaxis:FeatureIdAxis" xmi:id="_67WWBdlSEeWE_b6VdATlFQ" element="property_of_stereotype:/RootElement::Package1::Package1_1::Stereotype3::Attribute3_2"> + <manager xmi:type="nattableaxisconfiguration:AxisManagerRepresentation" href="platform:/plugin/org.eclipse.papyrus.uml.nattable.generic.config/configs/generic.nattableconfiguration#//@columnHeaderAxisConfiguration/@axisManagers.1"/> + </axis> + </columnAxisProvidersHistory> + <rowAxisProvidersHistory xmi:type="nattableaxisprovider:MasterObjectAxisProvider" xmi:id="_6rKk8tlSEeWE_b6VdATlFQ" description="This axis provider contains the object dropped by the user into the table" name="DroppedElementAxisProvider" disconnectSlave="true"> + <axis xmi:type="nattableaxis:EObjectAxis" xmi:id="_66tc0NlSEeWE_b6VdATlFQ"> + <manager xmi:type="nattableaxisconfiguration:AxisManagerRepresentation" href="platform:/plugin/org.eclipse.papyrus.uml.nattable.generic.config/configs/generic.nattableconfiguration#//@rowHeaderAxisConfiguration/@axisManagers.0"/> + <element xmi:type="uml:Class" href="488082.uml#_4Y5nYNlSEeWE_b6VdATlFQ"/> + </axis> + </rowAxisProvidersHistory> +</nattable:Table> diff --git a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/resources/bugs/bug488082/488082.profile.di b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/resources/bugs/bug488082/488082.profile.di new file mode 100644 index 00000000000..bf9abab340f --- /dev/null +++ b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/resources/bugs/bug488082/488082.profile.di @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="UTF-8"?> +<xmi:XMI xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI"/> diff --git a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/resources/bugs/bug488082/488082.profile.notation b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/resources/bugs/bug488082/488082.profile.notation new file mode 100644 index 00000000000..99be5ceb4cd --- /dev/null +++ b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/resources/bugs/bug488082/488082.profile.notation @@ -0,0 +1,155 @@ +<?xml version="1.0" encoding="UTF-8"?> +<notation:Diagram xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:notation="http://www.eclipse.org/gmf/runtime/1.0.2/notation" xmlns:style="http://www.eclipse.org/papyrus/infra/viewpoints/policy/style" xmlns:uml="http://www.eclipse.org/uml2/5.0.0/UML" xmi:id="_o5lzANlNEeWbEpm2b0WIXQ" type="PapyrusUMLProfileDiagram" name="Profile Diagram" measurementUnit="Pixel"> + <children xmi:type="notation:Shape" xmi:id="_punWgNlNEeWbEpm2b0WIXQ" type="2007"> + <children xmi:type="notation:DecorationNode" xmi:id="_pu5DUNlNEeWbEpm2b0WIXQ" type="5026"/> + <children xmi:type="notation:DecorationNode" xmi:id="_pu6RcNlNEeWbEpm2b0WIXQ" type="1005"> + <children xmi:type="notation:Shape" xmi:id="_cpL74NlOEeWbEpm2b0WIXQ" type="1024"> + <children xmi:type="notation:DecorationNode" xmi:id="_cpMi8dlOEeWbEpm2b0WIXQ" type="1050"/> + <children xmi:type="notation:DecorationNode" xmi:id="_cpMi8tlOEeWbEpm2b0WIXQ" type="1051"> + <children xmi:type="notation:Shape" xmi:id="_b_oBgNlOEeWbEpm2b0WIXQ" type="1023"> + <children xmi:type="notation:DecorationNode" xmi:id="_b_oBgtlOEeWbEpm2b0WIXQ" type="1046"/> + <children xmi:type="notation:BasicCompartment" xmi:id="_b_p2sNlOEeWbEpm2b0WIXQ" type="1052"> + <children xmi:type="notation:Shape" xmi:id="_d-jMUNlOEeWbEpm2b0WIXQ" type="3002"> + <element xmi:type="uml:Property" href="488082.profile.uml#_d-SGkNlOEeWbEpm2b0WIXQ"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_d-jMUdlOEeWbEpm2b0WIXQ"/> + </children> + <children xmi:type="notation:Shape" xmi:id="_eS8vANlOEeWbEpm2b0WIXQ" type="3002"> + <element xmi:type="uml:Property" href="488082.profile.uml#_eS0MINlOEeWbEpm2b0WIXQ"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_eS8vAdlOEeWbEpm2b0WIXQ"/> + </children> + <styles xmi:type="notation:TitleStyle" xmi:id="_b_p2sdlOEeWbEpm2b0WIXQ"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_b_p2stlOEeWbEpm2b0WIXQ"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_b_p2s9lOEeWbEpm2b0WIXQ"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_b_p2tNlOEeWbEpm2b0WIXQ"/> + </children> + <children xmi:type="notation:BasicCompartment" xmi:id="_b_p2tdlOEeWbEpm2b0WIXQ" type="1053"> + <styles xmi:type="notation:TitleStyle" xmi:id="_b_p2ttlOEeWbEpm2b0WIXQ"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_b_p2t9lOEeWbEpm2b0WIXQ"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_b_p2uNlOEeWbEpm2b0WIXQ"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_b_p2udlOEeWbEpm2b0WIXQ"/> + </children> + <element xmi:type="uml:Stereotype" href="488082.profile.uml#_b_TRYNlOEeWbEpm2b0WIXQ"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_b_oBgdlOEeWbEpm2b0WIXQ" x="14" y="11"/> + </children> + <styles xmi:type="notation:TitleStyle" xmi:id="_cpMi89lOEeWbEpm2b0WIXQ"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_cpMi9NlOEeWbEpm2b0WIXQ"/> + </children> + <element xmi:type="uml:Profile" href="488082.profile.uml#_cpEnINlOEeWbEpm2b0WIXQ"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_cpMi8NlOEeWbEpm2b0WIXQ" x="22" y="35"/> + </children> + <children xmi:type="notation:Shape" xmi:id="_2nlXkNlOEeWbEpm2b0WIXQ" type="1023"> + <children xmi:type="notation:DecorationNode" xmi:id="_2nlXktlOEeWbEpm2b0WIXQ" type="1046"/> + <children xmi:type="notation:BasicCompartment" xmi:id="_2nl-oNlOEeWbEpm2b0WIXQ" type="1052"> + <children xmi:type="notation:Shape" xmi:id="_3i2F8NlOEeWbEpm2b0WIXQ" type="3002"> + <element xmi:type="uml:Property" href="488082.profile.uml#_3isU8NlOEeWbEpm2b0WIXQ"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_3i2F8dlOEeWbEpm2b0WIXQ"/> + </children> + <children xmi:type="notation:Shape" xmi:id="_3t--8NlOEeWbEpm2b0WIXQ" type="3002"> + <element xmi:type="uml:Property" href="488082.profile.uml#_3tpAsNlOEeWbEpm2b0WIXQ"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_3t--8dlOEeWbEpm2b0WIXQ"/> + </children> + <styles xmi:type="notation:TitleStyle" xmi:id="_2nl-odlOEeWbEpm2b0WIXQ"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_2nl-otlOEeWbEpm2b0WIXQ"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_2nl-o9lOEeWbEpm2b0WIXQ"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_2nl-pNlOEeWbEpm2b0WIXQ"/> + </children> + <children xmi:type="notation:BasicCompartment" xmi:id="_2nl-pdlOEeWbEpm2b0WIXQ" type="1053"> + <styles xmi:type="notation:TitleStyle" xmi:id="_2nl-ptlOEeWbEpm2b0WIXQ"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_2nl-p9lOEeWbEpm2b0WIXQ"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_2nl-qNlOEeWbEpm2b0WIXQ"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_2nl-qdlOEeWbEpm2b0WIXQ"/> + </children> + <element xmi:type="uml:Stereotype" href="488082.profile.uml#_1zkgsNlOEeWbEpm2b0WIXQ"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_2nlXkdlOEeWbEpm2b0WIXQ" x="325" y="82" width="317" height="133"/> + </children> + <children xmi:type="notation:Shape" xmi:id="_8t5HINlREeWE_b6VdATlFQ" type="1012"> + <children xmi:type="notation:DecorationNode" xmi:id="_8t68UNlREeWE_b6VdATlFQ" type="1010"/> + <children xmi:type="notation:DecorationNode" xmi:id="_8t68UdlREeWE_b6VdATlFQ" type="11"> + <children xmi:type="notation:Shape" xmi:id="_9DRhQNlREeWE_b6VdATlFQ" type="1023"> + <children xmi:type="notation:DecorationNode" xmi:id="_9DRhQtlREeWE_b6VdATlFQ" type="1046"/> + <children xmi:type="notation:BasicCompartment" xmi:id="_9DRhQ9lREeWE_b6VdATlFQ" type="1052"> + <children xmi:type="notation:Shape" xmi:id="__T2cwNlREeWE_b6VdATlFQ" type="3002"> + <element xmi:type="uml:Property" href="488082.profile.uml#__TpBYNlREeWE_b6VdATlFQ"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="__T2cwdlREeWE_b6VdATlFQ"/> + </children> + <children xmi:type="notation:Shape" xmi:id="__hsEcNlREeWE_b6VdATlFQ" type="3002"> + <element xmi:type="uml:Property" href="488082.profile.uml#__hLuINlREeWE_b6VdATlFQ"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="__hsEcdlREeWE_b6VdATlFQ"/> + </children> + <styles xmi:type="notation:TitleStyle" xmi:id="_9DRhRNlREeWE_b6VdATlFQ"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_9DRhRdlREeWE_b6VdATlFQ"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_9DRhRtlREeWE_b6VdATlFQ"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_9DRhR9lREeWE_b6VdATlFQ"/> + </children> + <children xmi:type="notation:BasicCompartment" xmi:id="_9DRhSNlREeWE_b6VdATlFQ" type="1053"> + <styles xmi:type="notation:TitleStyle" xmi:id="_9DRhSdlREeWE_b6VdATlFQ"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_9DRhStlREeWE_b6VdATlFQ"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_9DRhS9lREeWE_b6VdATlFQ"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_9DRhTNlREeWE_b6VdATlFQ"/> + </children> + <element xmi:type="uml:Stereotype" href="488082.profile.uml#_9CzAINlREeWE_b6VdATlFQ"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_9DRhQdlREeWE_b6VdATlFQ" x="192" y="52"/> + </children> + <styles xmi:type="notation:TitleStyle" xmi:id="_8t68UtlREeWE_b6VdATlFQ"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_8t68U9lREeWE_b6VdATlFQ"/> + </children> + <element xmi:type="uml:Package" href="488082.profile.uml#_8tcbMNlREeWE_b6VdATlFQ"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_8t5HIdlREeWE_b6VdATlFQ" x="678" y="17" width="564" height="237"/> + </children> + <styles xmi:type="notation:TitleStyle" xmi:id="_pu6RcdlNEeWbEpm2b0WIXQ"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_pu6RctlNEeWbEpm2b0WIXQ"/> + </children> + <element xmi:type="uml:Package" href="488082.profile.uml#_puXe4NlNEeWbEpm2b0WIXQ"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_pun9kNlNEeWbEpm2b0WIXQ" x="49" y="188" width="1270" height="307"/> + </children> + <children xmi:type="notation:Shape" xmi:id="_rRELQNlOEeWbEpm2b0WIXQ" type="1031"> + <children xmi:type="notation:DecorationNode" xmi:id="_rRFZYNlOEeWbEpm2b0WIXQ" type="1084"/> + <element xmi:type="uml:Class" href="pathmap://UML_METAMODELS/UML.metamodel.uml#Class"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_rRGAcNlOEeWbEpm2b0WIXQ" x="548" y="72"/> + </children> + <children xmi:type="notation:Shape" xmi:id="_rRu5oNlOEeWbEpm2b0WIXQ" type="StereotypeComment"> + <styles xmi:type="notation:TitleStyle" xmi:id="_rRu5odlOEeWbEpm2b0WIXQ" showTitle="true"/> + <styles xmi:type="notation:EObjectValueStyle" xmi:id="_rRwHwNlOEeWbEpm2b0WIXQ" name="BASE_ELEMENT"> + <eObjectValue xmi:type="uml:Class" href="pathmap://UML_METAMODELS/UML.metamodel.uml#Class"/> + </styles> + <element xsi:nil="true"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_rRu5otlOEeWbEpm2b0WIXQ" x="748" y="72"/> + </children> + <styles xmi:type="notation:StringValueStyle" xmi:id="_o5lzAdlNEeWbEpm2b0WIXQ" name="diagram_compatibility_version" stringValue="1.1.0"/> + <styles xmi:type="notation:DiagramStyle" xmi:id="_o5lzAtlNEeWbEpm2b0WIXQ"/> + <styles xmi:type="style:PapyrusViewStyle" xmi:id="_o5lzA9lNEeWbEpm2b0WIXQ"> + <owner xmi:type="uml:Profile" href="488082.profile.uml#_o4C64NlNEeWbEpm2b0WIXQ"/> + </styles> + <element xmi:type="uml:Profile" href="488082.profile.uml#_o4C64NlNEeWbEpm2b0WIXQ"/> + <edges xmi:type="notation:Connector" xmi:id="_rR1nUNlOEeWbEpm2b0WIXQ" type="StereotypeCommentLink" source="_rRELQNlOEeWbEpm2b0WIXQ" target="_rRu5oNlOEeWbEpm2b0WIXQ"> + <styles xmi:type="notation:FontStyle" xmi:id="_rR1nUdlOEeWbEpm2b0WIXQ"/> + <styles xmi:type="notation:EObjectValueStyle" xmi:id="_rR21ctlOEeWbEpm2b0WIXQ" name="BASE_ELEMENT"> + <eObjectValue xmi:type="uml:Class" href="pathmap://UML_METAMODELS/UML.metamodel.uml#Class"/> + </styles> + <element xsi:nil="true"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_rR1nUtlOEeWbEpm2b0WIXQ" points="[0, 0, 0, 0]$[0, 0, 0, 0]"/> + <sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="_rR21cNlOEeWbEpm2b0WIXQ"/> + <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_rR21cdlOEeWbEpm2b0WIXQ"/> + </edges> + <edges xmi:type="notation:Connector" xmi:id="_rz2IMNlOEeWbEpm2b0WIXQ" type="1013" source="_b_oBgNlOEeWbEpm2b0WIXQ" target="_rRELQNlOEeWbEpm2b0WIXQ"> + <styles xmi:type="notation:FontStyle" xmi:id="_rz2IMdlOEeWbEpm2b0WIXQ"/> + <element xmi:type="uml:Extension" href="488082.profile.uml#_rzN2ENlOEeWbEpm2b0WIXQ"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_rz2IMtlOEeWbEpm2b0WIXQ" points="[-7, -22, 81, 203]$[-38, -226, 50, -1]"/> + <sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="_r1FeUNlOEeWbEpm2b0WIXQ" id="(0.7263157894736842,0.0)"/> + <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_r1FeUdlOEeWbEpm2b0WIXQ" id="(0.75,1.0)"/> + </edges> + <edges xmi:type="notation:Connector" xmi:id="_4ToCoNlOEeWbEpm2b0WIXQ" type="1013" source="_2nlXkNlOEeWbEpm2b0WIXQ" target="_rRELQNlOEeWbEpm2b0WIXQ"> + <styles xmi:type="notation:FontStyle" xmi:id="_4ToCodlOEeWbEpm2b0WIXQ"/> + <element xmi:type="uml:Extension" href="488082.profile.uml#_4TRdUNlOEeWbEpm2b0WIXQ"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_4ToCotlOEeWbEpm2b0WIXQ" points="[-108, -66, 315, 193]$[-376, -234, 47, 25]"/> + <sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="_4T69kNlOEeWbEpm2b0WIXQ" id="(0.21766561514195584,0.0)"/> + <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_4T69kdlOEeWbEpm2b0WIXQ" id="(0.95,1.0)"/> + </edges> + <edges xmi:type="notation:Connector" xmi:id="_BXaP8NlSEeWE_b6VdATlFQ" type="1013" source="_9DRhQNlREeWE_b6VdATlFQ" target="_rRELQNlOEeWbEpm2b0WIXQ"> + <styles xmi:type="notation:FontStyle" xmi:id="_BXaP8dlSEeWE_b6VdATlFQ"/> + <element xmi:type="uml:Extension" href="488082.profile.uml#_BXDDkNlSEeWE_b6VdATlFQ"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_BXaP8tlSEeWE_b6VdATlFQ" points="[-49, -26, 371, 203]$[-419, -204, 1, 25]"/> + <sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="_BYCiENlSEeWE_b6VdATlFQ" id="(0.19900497512437812,0.0)"/> + <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_BYDJINlSEeWE_b6VdATlFQ" id="(0.91,1.0)"/> + </edges> +</notation:Diagram> diff --git a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/resources/bugs/bug488082/488082.profile.uml b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/resources/bugs/bug488082/488082.profile.uml new file mode 100644 index 00000000000..846c3453ddf --- /dev/null +++ b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/resources/bugs/bug488082/488082.profile.uml @@ -0,0 +1,291 @@ +<?xml version="1.0" encoding="UTF-8"?> +<uml:Profile xmi:version="20131001" xmlns:xmi="http://www.omg.org/spec/XMI/20131001" xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" xmlns:uml="http://www.eclipse.org/uml2/5.0.0/UML" xmi:id="_o4C64NlNEeWbEpm2b0WIXQ" name="RootElement" metaclassReference="_rQu0ENlOEeWbEpm2b0WIXQ"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_f2VNUNlOEeWbEpm2b0WIXQ" source="http://www.eclipse.org/uml2/2.0.0/UML"> + <contents xmi:type="ecore:EPackage" xmi:id="_n3LFANlTEeWE_b6VdATlFQ" name="RootElement" nsURI="http:///schemas/RootElement/_n3Kd8NlTEeWE_b6VdATlFQ/4" nsPrefix="RootElement"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_n3LFAdlTEeWE_b6VdATlFQ" source="http://www.eclipse.org/uml2/4.0.0/UML" references="_cpEnINlOEeWbEpm2b0WIXQ"/> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_n3MTINlTEeWE_b6VdATlFQ" source="PapyrusVersion"> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_n3MTIdlTEeWE_b6VdATlFQ" key="Version" value="0.0.5"/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_n3MTItlTEeWE_b6VdATlFQ" key="Comment" value=""/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_n3MTI9lTEeWE_b6VdATlFQ" key="Copyright" value=""/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_n3MTJNlTEeWE_b6VdATlFQ" key="Date" value="2016-02-22"/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_n3MTJdlTEeWE_b6VdATlFQ" key="Author" value=""/> + </eAnnotations> + <eSubpackages xmi:type="ecore:EPackage" xmi:id="_n3LFAtlTEeWE_b6VdATlFQ" name="Package1" nsURI="http:///RootElement/Package1.ecore" nsPrefix="RootElement.Package1"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_n3LFA9lTEeWE_b6VdATlFQ" source="http://www.eclipse.org/uml2/4.0.0/UML" references="_puXe4NlNEeWbEpm2b0WIXQ"/> + <eClassifiers xmi:type="ecore:EClass" xmi:id="_n3LFBNlTEeWE_b6VdATlFQ" name="Stereotype2"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_n3LFBdlTEeWE_b6VdATlFQ" source="http://www.eclipse.org/uml2/2.0.0/UML" references="_1zkgsNlOEeWbEpm2b0WIXQ"/> + <eStructuralFeatures xmi:type="ecore:EAttribute" xmi:id="_n3LFBtlTEeWE_b6VdATlFQ" name="Attribute2_1" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EDataType" href="http://www.eclipse.org/uml2/5.0.0/Types#//Integer"/> + </eStructuralFeatures> + <eStructuralFeatures xmi:type="ecore:EAttribute" xmi:id="_n3LFCNlTEeWE_b6VdATlFQ" name="Attribute2_2" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EDataType" href="http://www.eclipse.org/uml2/5.0.0/Types#//String"/> + </eStructuralFeatures> + <eStructuralFeatures xmi:type="ecore:EReference" xmi:id="_n3LFCtlTEeWE_b6VdATlFQ" name="base_Class" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EClass" href="http://www.eclipse.org/uml2/5.0.0/UML#//Class"/> + </eStructuralFeatures> + </eClassifiers> + <eSubpackages xmi:type="ecore:EPackage" xmi:id="_n3LFDNlTEeWE_b6VdATlFQ" name="Package1_1" nsURI="http:///RootElement/Package1/Package1_1.ecore" nsPrefix="RootElement.Package1.Package1_1"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_n3LFDdlTEeWE_b6VdATlFQ" source="http://www.eclipse.org/uml2/4.0.0/UML" references="_8tcbMNlREeWE_b6VdATlFQ"/> + <eClassifiers xmi:type="ecore:EClass" xmi:id="_n3LFDtlTEeWE_b6VdATlFQ" name="Stereotype3"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_n3LFD9lTEeWE_b6VdATlFQ" source="http://www.eclipse.org/uml2/2.0.0/UML" references="_9CzAINlREeWE_b6VdATlFQ"/> + <eStructuralFeatures xmi:type="ecore:EAttribute" xmi:id="_n3LFENlTEeWE_b6VdATlFQ" name="Attribute3_1" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EDataType" href="http://www.eclipse.org/uml2/5.0.0/Types#//Real"/> + </eStructuralFeatures> + <eStructuralFeatures xmi:type="ecore:EAttribute" xmi:id="_n3LFEtlTEeWE_b6VdATlFQ" name="Attribute3_2" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EDataType" href="http://www.eclipse.org/uml2/5.0.0/Types#//String"/> + </eStructuralFeatures> + <eStructuralFeatures xmi:type="ecore:EReference" xmi:id="_n3LFFNlTEeWE_b6VdATlFQ" name="base_Class" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EClass" href="http://www.eclipse.org/uml2/5.0.0/UML#//Class"/> + </eStructuralFeatures> + </eClassifiers> + </eSubpackages> + </eSubpackages> + </contents> + <contents xmi:type="ecore:EPackage" xmi:id="_B2djcNlSEeWE_b6VdATlFQ" name="RootElement" nsURI="http:///schemas/RootElement/_B2bHMNlSEeWE_b6VdATlFQ/3" nsPrefix="RootElement"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_B2djcdlSEeWE_b6VdATlFQ" source="http://www.eclipse.org/uml2/4.0.0/UML" references="_cpEnINlOEeWbEpm2b0WIXQ"/> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_B2fYoNlSEeWE_b6VdATlFQ" source="PapyrusVersion"> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_B2fYodlSEeWE_b6VdATlFQ" key="Version" value="0.0.4"/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_B2fYotlSEeWE_b6VdATlFQ" key="Comment" value=""/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_B2fYo9lSEeWE_b6VdATlFQ" key="Copyright" value=""/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_B2fYpNlSEeWE_b6VdATlFQ" key="Date" value="2016-02-22"/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_B2fYpdlSEeWE_b6VdATlFQ" key="Author" value=""/> + </eAnnotations> + <eSubpackages xmi:type="ecore:EPackage" xmi:id="_B2djctlSEeWE_b6VdATlFQ" name="Package1" nsURI="http:///RootElement/Package1.ecore" nsPrefix="RootElement.Package1"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_B2djc9lSEeWE_b6VdATlFQ" source="http://www.eclipse.org/uml2/4.0.0/UML" references="_puXe4NlNEeWbEpm2b0WIXQ"/> + <eClassifiers xmi:type="ecore:EClass" xmi:id="_B2djdNlSEeWE_b6VdATlFQ" name="Stereotype2"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_B2djddlSEeWE_b6VdATlFQ" source="http://www.eclipse.org/uml2/2.0.0/UML" references="_1zkgsNlOEeWbEpm2b0WIXQ"/> + <eStructuralFeatures xmi:type="ecore:EReference" xmi:id="_B2djdtlSEeWE_b6VdATlFQ" name="Attribute2_1" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EClass" href="http://www.eclipse.org/emf/2002/Ecore#//EObject"/> + </eStructuralFeatures> + <eStructuralFeatures xmi:type="ecore:EReference" xmi:id="_B2djeNlSEeWE_b6VdATlFQ" name="Attribute2_2" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EClass" href="http://www.eclipse.org/emf/2002/Ecore#//EObject"/> + </eStructuralFeatures> + <eStructuralFeatures xmi:type="ecore:EReference" xmi:id="_B2djetlSEeWE_b6VdATlFQ" name="base_Class" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EClass" href="http://www.eclipse.org/uml2/5.0.0/UML#//Class"/> + </eStructuralFeatures> + </eClassifiers> + <eSubpackages xmi:type="ecore:EPackage" xmi:id="_B2djfNlSEeWE_b6VdATlFQ" name="Package1_1" nsURI="http:///RootElement/Package1/Package1_1.ecore" nsPrefix="RootElement.Package1.Package1_1"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_B2djfdlSEeWE_b6VdATlFQ" source="http://www.eclipse.org/uml2/4.0.0/UML" references="_8tcbMNlREeWE_b6VdATlFQ"/> + <eClassifiers xmi:type="ecore:EClass" xmi:id="_B2djftlSEeWE_b6VdATlFQ" name="Stereotype3"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_B2djf9lSEeWE_b6VdATlFQ" source="http://www.eclipse.org/uml2/2.0.0/UML" references="_9CzAINlREeWE_b6VdATlFQ"/> + <eStructuralFeatures xmi:type="ecore:EReference" xmi:id="_B2djgNlSEeWE_b6VdATlFQ" name="Attribute3_1" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EClass" href="http://www.eclipse.org/emf/2002/Ecore#//EObject"/> + </eStructuralFeatures> + <eStructuralFeatures xmi:type="ecore:EReference" xmi:id="_B2djgtlSEeWE_b6VdATlFQ" name="Attribute3_2" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EClass" href="http://www.eclipse.org/emf/2002/Ecore#//EObject"/> + </eStructuralFeatures> + <eStructuralFeatures xmi:type="ecore:EReference" xmi:id="_B2djhNlSEeWE_b6VdATlFQ" name="base_Class" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EClass" href="http://www.eclipse.org/uml2/5.0.0/UML#//Class"/> + </eStructuralFeatures> + </eClassifiers> + </eSubpackages> + </eSubpackages> + </contents> + <contents xmi:type="ecore:EPackage" xmi:id="_4xBJQdlOEeWbEpm2b0WIXQ" name="RootElement" nsURI="http:///schemas/RootElement/_4xBJQNlOEeWbEpm2b0WIXQ/2" nsPrefix="RootElement"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_4xBJQtlOEeWbEpm2b0WIXQ" source="http://www.eclipse.org/uml2/4.0.0/UML" references="_cpEnINlOEeWbEpm2b0WIXQ"/> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_4xBwUNlOEeWbEpm2b0WIXQ" source="PapyrusVersion"> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_4xBwUdlOEeWbEpm2b0WIXQ" key="Version" value="0.0.3"/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_4xBwUtlOEeWbEpm2b0WIXQ" key="Comment" value=""/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_4xBwU9lOEeWbEpm2b0WIXQ" key="Copyright" value=""/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_4xBwVNlOEeWbEpm2b0WIXQ" key="Date" value="2016-02-22"/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_4xBwVdlOEeWbEpm2b0WIXQ" key="Author" value=""/> + </eAnnotations> + <eSubpackages xmi:type="ecore:EPackage" xmi:id="_4xBJQ9lOEeWbEpm2b0WIXQ" name="Package1" nsURI="http:///RootElement/Package1.ecore" nsPrefix="RootElement.Package1"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_4xBJRNlOEeWbEpm2b0WIXQ" source="http://www.eclipse.org/uml2/4.0.0/UML" references="_puXe4NlNEeWbEpm2b0WIXQ"/> + <eClassifiers xmi:type="ecore:EClass" xmi:id="_4xBJRdlOEeWbEpm2b0WIXQ" name="Stereotype2"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_4xBJRtlOEeWbEpm2b0WIXQ" source="http://www.eclipse.org/uml2/2.0.0/UML" references="_1zkgsNlOEeWbEpm2b0WIXQ"/> + <eStructuralFeatures xmi:type="ecore:EReference" xmi:id="_4xBJR9lOEeWbEpm2b0WIXQ" name="Attribute1" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EClass" href="http://www.eclipse.org/emf/2002/Ecore#//EObject"/> + </eStructuralFeatures> + <eStructuralFeatures xmi:type="ecore:EReference" xmi:id="_4xBJSdlOEeWbEpm2b0WIXQ" name="Attribute2" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EClass" href="http://www.eclipse.org/emf/2002/Ecore#//EObject"/> + </eStructuralFeatures> + <eStructuralFeatures xmi:type="ecore:EReference" xmi:id="_4xBJS9lOEeWbEpm2b0WIXQ" name="base_Class" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EClass" href="http://www.eclipse.org/uml2/5.0.0/UML#//Class"/> + </eStructuralFeatures> + </eClassifiers> + </eSubpackages> + </contents> + <contents xmi:type="ecore:EPackage" xmi:id="_sSBR8NlOEeWbEpm2b0WIXQ" name="RootElement" nsURI="http:///schemas/RootElement/_sSAq4NlOEeWbEpm2b0WIXQ/1" nsPrefix="RootElement"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_sSBR8dlOEeWbEpm2b0WIXQ" source="http://www.eclipse.org/uml2/4.0.0/UML" references="_cpEnINlOEeWbEpm2b0WIXQ"/> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_sSCgENlOEeWbEpm2b0WIXQ" source="PapyrusVersion"> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_sSCgEdlOEeWbEpm2b0WIXQ" key="Version" value="0.0.2"/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_sSCgEtlOEeWbEpm2b0WIXQ" key="Comment" value=""/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_sSCgE9lOEeWbEpm2b0WIXQ" key="Copyright" value=""/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_sSCgFNlOEeWbEpm2b0WIXQ" key="Date" value="2016-02-22"/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_sSCgFdlOEeWbEpm2b0WIXQ" key="Author" value=""/> + </eAnnotations> + <eSubpackages xmi:type="ecore:EPackage" xmi:id="_sSBR8tlOEeWbEpm2b0WIXQ" name="Package1" nsURI="http:///RootElement/Package1.ecore" nsPrefix="RootElement.Package1"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_sSBR89lOEeWbEpm2b0WIXQ" source="http://www.eclipse.org/uml2/4.0.0/UML" references="_puXe4NlNEeWbEpm2b0WIXQ"/> + </eSubpackages> + </contents> + <contents xmi:type="ecore:EPackage" xmi:id="_f2V0YNlOEeWbEpm2b0WIXQ" name="RootElement" nsURI="http:///schemas/RootElement/_f2UmQNlOEeWbEpm2b0WIXQ/0" nsPrefix="RootElement"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_f2V0YdlOEeWbEpm2b0WIXQ" source="http://www.eclipse.org/uml2/4.0.0/UML" references="_cpEnINlOEeWbEpm2b0WIXQ"/> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_f2aF0NlOEeWbEpm2b0WIXQ" source="PapyrusVersion"> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_f2aF0dlOEeWbEpm2b0WIXQ" key="Version" value="0.0.1"/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_f2aF0tlOEeWbEpm2b0WIXQ" key="Comment" value=""/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_f2aF09lOEeWbEpm2b0WIXQ" key="Copyright" value=""/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_f2aF1NlOEeWbEpm2b0WIXQ" key="Date" value="2016-02-22"/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_f2aF1dlOEeWbEpm2b0WIXQ" key="Author" value=""/> + </eAnnotations> + <eSubpackages xmi:type="ecore:EPackage" xmi:id="_f2V0YtlOEeWbEpm2b0WIXQ" name="Package1" nsURI="http:///RootElement/Package1.ecore" nsPrefix="RootElement.Package1"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_f2V0Y9lOEeWbEpm2b0WIXQ" source="http://www.eclipse.org/uml2/4.0.0/UML" references="_puXe4NlNEeWbEpm2b0WIXQ"/> + </eSubpackages> + </contents> + </eAnnotations> + <elementImport xmi:type="uml:ElementImport" xmi:id="_rQu0ENlOEeWbEpm2b0WIXQ" alias="Class"> + <importedElement xmi:type="uml:Class" href="pathmap://UML_METAMODELS/UML.metamodel.uml#Class"/> + </elementImport> + <packagedElement xmi:type="uml:Package" xmi:id="_puXe4NlNEeWbEpm2b0WIXQ" name="Package1"> + <packagedElement xmi:type="uml:Profile" xmi:id="_cpEnINlOEeWbEpm2b0WIXQ" name="Profile1"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_f2Y3sNlOEeWbEpm2b0WIXQ" source="http://www.eclipse.org/uml2/2.0.0/UML"> + <contents xmi:type="ecore:EPackage" xmi:id="_n3LsEdlTEeWE_b6VdATlFQ" name="Profile1" nsURI="http://RootElement.Package1/schemas/Profile1/_n3LsENlTEeWE_b6VdATlFQ/4" nsPrefix="Profile1"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_n3MTJ9lTEeWE_b6VdATlFQ" source="PapyrusVersion"> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_n3MTKNlTEeWE_b6VdATlFQ" key="Version" value="0.0.5"/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_n3MTKdlTEeWE_b6VdATlFQ" key="Comment" value=""/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_n3MTKtlTEeWE_b6VdATlFQ" key="Copyright" value=""/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_n3MTK9lTEeWE_b6VdATlFQ" key="Date" value="2016-02-22"/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_n3MTLNlTEeWE_b6VdATlFQ" key="Author" value=""/> + </eAnnotations> + <eClassifiers xmi:type="ecore:EClass" xmi:id="_n3LsEtlTEeWE_b6VdATlFQ" name="Stereotype1"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_n3LsE9lTEeWE_b6VdATlFQ" source="http://www.eclipse.org/uml2/2.0.0/UML" references="_b_TRYNlOEeWbEpm2b0WIXQ"/> + <eStructuralFeatures xmi:type="ecore:EAttribute" xmi:id="_n3LsFNlTEeWE_b6VdATlFQ" name="Attribute1_1" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EDataType" href="http://www.eclipse.org/uml2/5.0.0/Types#//Boolean"/> + </eStructuralFeatures> + <eStructuralFeatures xmi:type="ecore:EAttribute" xmi:id="_n3LsFtlTEeWE_b6VdATlFQ" name="Attribute1_2" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EDataType" href="http://www.eclipse.org/uml2/5.0.0/Types#//String"/> + </eStructuralFeatures> + <eStructuralFeatures xmi:type="ecore:EReference" xmi:id="_n3LsGNlTEeWE_b6VdATlFQ" name="base_Class" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EClass" href="http://www.eclipse.org/uml2/5.0.0/UML#//Class"/> + </eStructuralFeatures> + </eClassifiers> + </contents> + <contents xmi:type="ecore:EPackage" xmi:id="_B2eKgdlSEeWE_b6VdATlFQ" name="Profile1" nsURI="http://RootElement.Package1/schemas/Profile1/_B2eKgNlSEeWE_b6VdATlFQ/3" nsPrefix="Profile1"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_B2f_sdlSEeWE_b6VdATlFQ" source="PapyrusVersion"> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_B2f_stlSEeWE_b6VdATlFQ" key="Version" value="0.0.4"/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_B2f_s9lSEeWE_b6VdATlFQ" key="Comment" value=""/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_B2f_tNlSEeWE_b6VdATlFQ" key="Copyright" value=""/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_B2f_tdlSEeWE_b6VdATlFQ" key="Date" value="2016-02-22"/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_B2f_ttlSEeWE_b6VdATlFQ" key="Author" value=""/> + </eAnnotations> + <eClassifiers xmi:type="ecore:EClass" xmi:id="_B2eKgtlSEeWE_b6VdATlFQ" name="Stereotype1"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_B2eKg9lSEeWE_b6VdATlFQ" source="http://www.eclipse.org/uml2/2.0.0/UML" references="_b_TRYNlOEeWbEpm2b0WIXQ"/> + <eStructuralFeatures xmi:type="ecore:EReference" xmi:id="_B2eKhNlSEeWE_b6VdATlFQ" name="Attribute1_1" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EClass" href="http://www.eclipse.org/emf/2002/Ecore#//EObject"/> + </eStructuralFeatures> + <eStructuralFeatures xmi:type="ecore:EReference" xmi:id="_B2eKhtlSEeWE_b6VdATlFQ" name="Attribute1_2" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EClass" href="http://www.eclipse.org/emf/2002/Ecore#//EObject"/> + </eStructuralFeatures> + <eStructuralFeatures xmi:type="ecore:EReference" xmi:id="_B2eKiNlSEeWE_b6VdATlFQ" name="base_Class" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EClass" href="http://www.eclipse.org/uml2/5.0.0/UML#//Class"/> + </eStructuralFeatures> + </eClassifiers> + </contents> + <contents xmi:type="ecore:EPackage" xmi:id="_4xBJTtlOEeWbEpm2b0WIXQ" name="Profile1" nsURI="http://RootElement.Package1/schemas/Profile1/_4xBJTdlOEeWbEpm2b0WIXQ/2" nsPrefix="Profile1"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_4xCXYNlOEeWbEpm2b0WIXQ" source="PapyrusVersion"> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_4xCXYdlOEeWbEpm2b0WIXQ" key="Version" value="0.0.3"/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_4xCXYtlOEeWbEpm2b0WIXQ" key="Comment" value=""/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_4xCXY9lOEeWbEpm2b0WIXQ" key="Copyright" value=""/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_4xCXZNlOEeWbEpm2b0WIXQ" key="Date" value="2016-02-22"/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_4xCXZdlOEeWbEpm2b0WIXQ" key="Author" value=""/> + </eAnnotations> + <eClassifiers xmi:type="ecore:EClass" xmi:id="_4xBJT9lOEeWbEpm2b0WIXQ" name="Stereotype1"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_4xBJUNlOEeWbEpm2b0WIXQ" source="http://www.eclipse.org/uml2/2.0.0/UML" references="_b_TRYNlOEeWbEpm2b0WIXQ"/> + <eStructuralFeatures xmi:type="ecore:EReference" xmi:id="_4xBJUdlOEeWbEpm2b0WIXQ" name="Attribute1" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EClass" href="http://www.eclipse.org/emf/2002/Ecore#//EObject"/> + </eStructuralFeatures> + <eStructuralFeatures xmi:type="ecore:EReference" xmi:id="_4xBJU9lOEeWbEpm2b0WIXQ" name="Attribute2" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EClass" href="http://www.eclipse.org/emf/2002/Ecore#//EObject"/> + </eStructuralFeatures> + <eStructuralFeatures xmi:type="ecore:EReference" xmi:id="_4xBJVdlOEeWbEpm2b0WIXQ" name="base_Class" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EClass" href="http://www.eclipse.org/uml2/5.0.0/UML#//Class"/> + </eStructuralFeatures> + </eClassifiers> + </contents> + <contents xmi:type="ecore:EPackage" xmi:id="_sSB5AdlOEeWbEpm2b0WIXQ" name="Profile1" nsURI="http://RootElement.Package1/schemas/Profile1/_sSB5ANlOEeWbEpm2b0WIXQ/1" nsPrefix="Profile1"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_sSDHIdlOEeWbEpm2b0WIXQ" source="PapyrusVersion"> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_sSDHItlOEeWbEpm2b0WIXQ" key="Version" value="0.0.2"/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_sSDHI9lOEeWbEpm2b0WIXQ" key="Comment" value=""/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_sSDHJNlOEeWbEpm2b0WIXQ" key="Copyright" value=""/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_sSDHJdlOEeWbEpm2b0WIXQ" key="Date" value="2016-02-22"/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_sSDHJtlOEeWbEpm2b0WIXQ" key="Author" value=""/> + </eAnnotations> + <eClassifiers xmi:type="ecore:EClass" xmi:id="_sSB5AtlOEeWbEpm2b0WIXQ" name="Stereotype1"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_sSB5A9lOEeWbEpm2b0WIXQ" source="http://www.eclipse.org/uml2/2.0.0/UML" references="_b_TRYNlOEeWbEpm2b0WIXQ"/> + <eStructuralFeatures xmi:type="ecore:EReference" xmi:id="_sSB5BNlOEeWbEpm2b0WIXQ" name="Attribute1" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EClass" href="http://www.eclipse.org/emf/2002/Ecore#//EObject"/> + </eStructuralFeatures> + <eStructuralFeatures xmi:type="ecore:EReference" xmi:id="_sSB5BtlOEeWbEpm2b0WIXQ" name="Attribute2" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EClass" href="http://www.eclipse.org/emf/2002/Ecore#//EObject"/> + </eStructuralFeatures> + <eStructuralFeatures xmi:type="ecore:EReference" xmi:id="_sSB5CNlOEeWbEpm2b0WIXQ" name="base_Class" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EClass" href="http://www.eclipse.org/uml2/5.0.0/UML#//Class"/> + </eStructuralFeatures> + </eClassifiers> + </contents> + <contents xmi:type="ecore:EPackage" xmi:id="_f2Y3sdlOEeWbEpm2b0WIXQ" name="Profile1" nsURI="http://RootElement.Package1/schemas/Profile1/_f2YQoNlOEeWbEpm2b0WIXQ/0" nsPrefix="Profile1"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_f2bT8tlOEeWbEpm2b0WIXQ" source="PapyrusVersion"> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_f2bT89lOEeWbEpm2b0WIXQ" key="Version" value="0.0.1"/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_f2bT9NlOEeWbEpm2b0WIXQ" key="Comment" value=""/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_f2bT9dlOEeWbEpm2b0WIXQ" key="Copyright" value=""/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_f2bT9tlOEeWbEpm2b0WIXQ" key="Date" value="2016-02-22"/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_f2bT99lOEeWbEpm2b0WIXQ" key="Author" value=""/> + </eAnnotations> + <eClassifiers xmi:type="ecore:EClass" xmi:id="_f2Y3stlOEeWbEpm2b0WIXQ" name="Stereotype1"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_f2Y3s9lOEeWbEpm2b0WIXQ" source="http://www.eclipse.org/uml2/2.0.0/UML" references="_b_TRYNlOEeWbEpm2b0WIXQ"/> + <eStructuralFeatures xmi:type="ecore:EReference" xmi:id="_f2Y3tNlOEeWbEpm2b0WIXQ" name="Attribute1" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EClass" href="http://www.eclipse.org/emf/2002/Ecore#//EObject"/> + </eStructuralFeatures> + <eStructuralFeatures xmi:type="ecore:EReference" xmi:id="_f2Y3ttlOEeWbEpm2b0WIXQ" name="Attribute2" ordered="false" lowerBound="1"> + <eType xmi:type="ecore:EClass" href="http://www.eclipse.org/emf/2002/Ecore#//EObject"/> + </eStructuralFeatures> + </eClassifiers> + </contents> + </eAnnotations> + <packagedElement xmi:type="uml:Stereotype" xmi:id="_b_TRYNlOEeWbEpm2b0WIXQ" name="Stereotype1"> + <ownedAttribute xmi:type="uml:Property" xmi:id="_d-SGkNlOEeWbEpm2b0WIXQ" name="Attribute1_1" visibility="public"> + <type xmi:type="uml:PrimitiveType" href="pathmap://UML_LIBRARIES/UMLPrimitiveTypes.library.uml#Boolean"/> + </ownedAttribute> + <ownedAttribute xmi:type="uml:Property" xmi:id="_eS0MINlOEeWbEpm2b0WIXQ" name="Attribute1_2" visibility="public"> + <type xmi:type="uml:PrimitiveType" href="pathmap://UML_LIBRARIES/UMLPrimitiveTypes.library.uml#String"/> + </ownedAttribute> + <ownedAttribute xmi:type="uml:Property" xmi:id="_rzSukNlOEeWbEpm2b0WIXQ" name="base_Class" association="_rzN2ENlOEeWbEpm2b0WIXQ"> + <type xmi:type="uml:Class" href="pathmap://UML_METAMODELS/UML.metamodel.uml#Class"/> + </ownedAttribute> + </packagedElement> + <packagedElement xmi:type="uml:Extension" xmi:id="_rzN2ENlOEeWbEpm2b0WIXQ" name="E_Stereotype1_Class1" memberEnd="_rzRgcNlOEeWbEpm2b0WIXQ _rzSukNlOEeWbEpm2b0WIXQ"> + <ownedEnd xmi:type="uml:ExtensionEnd" xmi:id="_rzRgcNlOEeWbEpm2b0WIXQ" name="extension_Stereotype1" type="_b_TRYNlOEeWbEpm2b0WIXQ" aggregation="composite" association="_rzN2ENlOEeWbEpm2b0WIXQ"/> + </packagedElement> + </packagedElement> + <packagedElement xmi:type="uml:Stereotype" xmi:id="_1zkgsNlOEeWbEpm2b0WIXQ" name="Stereotype2"> + <ownedAttribute xmi:type="uml:Property" xmi:id="_3isU8NlOEeWbEpm2b0WIXQ" name="Attribute2_1" visibility="public"> + <type xmi:type="uml:PrimitiveType" href="pathmap://UML_LIBRARIES/UMLPrimitiveTypes.library.uml#Integer"/> + </ownedAttribute> + <ownedAttribute xmi:type="uml:Property" xmi:id="_3tpAsNlOEeWbEpm2b0WIXQ" name="Attribute2_2" visibility="public"> + <type xmi:type="uml:PrimitiveType" href="pathmap://UML_LIBRARIES/UMLPrimitiveTypes.library.uml#String"/> + </ownedAttribute> + <ownedAttribute xmi:type="uml:Property" xmi:id="_4TSrcNlOEeWbEpm2b0WIXQ" name="base_Class" association="_4TRdUNlOEeWbEpm2b0WIXQ"> + <type xmi:type="uml:Class" href="pathmap://UML_METAMODELS/UML.metamodel.uml#Class"/> + </ownedAttribute> + </packagedElement> + <packagedElement xmi:type="uml:Extension" xmi:id="_4TRdUNlOEeWbEpm2b0WIXQ" name="E_Stereotype2_Class1" memberEnd="_4TSEYNlOEeWbEpm2b0WIXQ _4TSrcNlOEeWbEpm2b0WIXQ"> + <ownedEnd xmi:type="uml:ExtensionEnd" xmi:id="_4TSEYNlOEeWbEpm2b0WIXQ" name="extension_Stereotype2" type="_1zkgsNlOEeWbEpm2b0WIXQ" aggregation="composite" association="_4TRdUNlOEeWbEpm2b0WIXQ"/> + </packagedElement> + <packagedElement xmi:type="uml:Package" xmi:id="_8tcbMNlREeWE_b6VdATlFQ" name="Package1_1"> + <packagedElement xmi:type="uml:Stereotype" xmi:id="_9CzAINlREeWE_b6VdATlFQ" name="Stereotype3"> + <ownedAttribute xmi:type="uml:Property" xmi:id="__TpBYNlREeWE_b6VdATlFQ" name="Attribute3_1" visibility="public"> + <type xmi:type="uml:PrimitiveType" href="pathmap://UML_LIBRARIES/UMLPrimitiveTypes.library.uml#Real"/> + </ownedAttribute> + <ownedAttribute xmi:type="uml:Property" xmi:id="__hLuINlREeWE_b6VdATlFQ" name="Attribute3_2" visibility="public"> + <type xmi:type="uml:PrimitiveType" href="pathmap://UML_LIBRARIES/UMLPrimitiveTypes.library.uml#String"/> + </ownedAttribute> + <ownedAttribute xmi:type="uml:Property" xmi:id="_BXGt8NlSEeWE_b6VdATlFQ" name="base_Class" association="_BXDDkNlSEeWE_b6VdATlFQ"> + <type xmi:type="uml:Class" href="pathmap://UML_METAMODELS/UML.metamodel.uml#Class"/> + </ownedAttribute> + </packagedElement> + <packagedElement xmi:type="uml:Extension" xmi:id="_BXDDkNlSEeWE_b6VdATlFQ" name="E_Stereotype3_Class1" memberEnd="_BXGG4NlSEeWE_b6VdATlFQ _BXGt8NlSEeWE_b6VdATlFQ"> + <ownedEnd xmi:type="uml:ExtensionEnd" xmi:id="_BXGG4NlSEeWE_b6VdATlFQ" name="extension_Stereotype3" type="_9CzAINlREeWE_b6VdATlFQ" aggregation="composite" association="_BXDDkNlSEeWE_b6VdATlFQ"/> + </packagedElement> + </packagedElement> + </packagedElement> +</uml:Profile> diff --git a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/resources/bugs/bug488082/488082.uml b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/resources/bugs/bug488082/488082.uml new file mode 100644 index 00000000000..43107a13f4a --- /dev/null +++ b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/resources/bugs/bug488082/488082.uml @@ -0,0 +1,35 @@ +<?xml version="1.0" encoding="UTF-8"?> +<xmi:XMI xmi:version="20131001" xmlns:xmi="http://www.omg.org/spec/XMI/20131001" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:Profile1="http://RootElement.Package1/schemas/Profile1/_n3LsENlTEeWE_b6VdATlFQ/4" xmlns:RootElement.Package1="http:///RootElement/Package1.ecore" xmlns:RootElement.Package1.Package1_1="http:///RootElement/Package1/Package1_1.ecore" xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" xmlns:uml="http://www.eclipse.org/uml2/5.0.0/UML" xsi:schemaLocation="http://RootElement.Package1/schemas/Profile1/_n3LsENlTEeWE_b6VdATlFQ/4 488082.profile.uml#_n3LsEdlTEeWE_b6VdATlFQ http:///RootElement/Package1.ecore 488082.profile.uml#_n3LFAtlTEeWE_b6VdATlFQ http:///RootElement/Package1/Package1_1.ecore 488082.profile.uml#_n3LFDNlTEeWE_b6VdATlFQ"> + <uml:Model xmi:id="_jHhRQNlOEeWbEpm2b0WIXQ" name="RootElement"> + <packagedElement xmi:type="uml:Class" xmi:id="_4Y5nYNlSEeWE_b6VdATlFQ" name="Class1"/> + <profileApplication xmi:type="uml:ProfileApplication" xmi:id="_nGMGQNlOEeWbEpm2b0WIXQ"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_ooU1INlTEeWE_b6VdATlFQ" source="PapyrusVersion"> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_ooU1IdlTEeWE_b6VdATlFQ" key="Version" value="0.0.5"/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_ooU1ItlTEeWE_b6VdATlFQ" key="Comment" value=""/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_ooU1I9lTEeWE_b6VdATlFQ" key="Copyright" value=""/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_ooU1JNlTEeWE_b6VdATlFQ" key="Date" value="2016-02-22"/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_ooU1JdlTEeWE_b6VdATlFQ" key="Author" value=""/> + </eAnnotations> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_nGN7cNlOEeWbEpm2b0WIXQ" source="http://www.eclipse.org/uml2/2.0.0/UML"> + <references xmi:type="ecore:EPackage" href="488082.profile.uml#_n3LFANlTEeWE_b6VdATlFQ"/> + </eAnnotations> + <appliedProfile xmi:type="uml:Profile" href="488082.profile.uml#_o4C64NlNEeWbEpm2b0WIXQ"/> + </profileApplication> + <profileApplication xmi:type="uml:ProfileApplication" xmi:id="_nGQ-wNlOEeWbEpm2b0WIXQ"> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_ooVcMNlTEeWE_b6VdATlFQ" source="PapyrusVersion"> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_ooVcMdlTEeWE_b6VdATlFQ" key="Version" value="0.0.5"/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_ooVcMtlTEeWE_b6VdATlFQ" key="Comment" value=""/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_ooVcM9lTEeWE_b6VdATlFQ" key="Copyright" value=""/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_ooVcNNlTEeWE_b6VdATlFQ" key="Date" value="2016-02-22"/> + <details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_ooVcNdlTEeWE_b6VdATlFQ" key="Author" value=""/> + </eAnnotations> + <eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_nGRl0NlOEeWbEpm2b0WIXQ" source="http://www.eclipse.org/uml2/2.0.0/UML"> + <references xmi:type="ecore:EPackage" href="488082.profile.uml#_n3LsEdlTEeWE_b6VdATlFQ"/> + </eAnnotations> + <appliedProfile xmi:type="uml:Profile" href="488082.profile.uml#_cpEnINlOEeWbEpm2b0WIXQ"/> + </profileApplication> + </uml:Model> + <Profile1:Stereotype1 xmi:id="_5UwLoNlSEeWE_b6VdATlFQ" Attribute1_1="true" Attribute1_2="Test1" base_Class="_4Y5nYNlSEeWE_b6VdATlFQ"/> + <RootElement.Package1:Stereotype2 xmi:id="_5VCfgNlSEeWE_b6VdATlFQ" Attribute2_1="2" Attribute2_2="Test2" base_Class="_4Y5nYNlSEeWE_b6VdATlFQ"/> + <RootElement.Package1.Package1_1:Stereotype3 xmi:id="_5VOFsNlSEeWE_b6VdATlFQ" Attribute3_1="3.14" Attribute3_2="Test3" base_Class="_4Y5nYNlSEeWE_b6VdATlFQ"/> +</xmi:XMI> diff --git a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/src/org/eclipse/papyrus/uml/nattable/generic/tests/bugs/StereotypeSubPackagesDisplayTest.java b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/src/org/eclipse/papyrus/uml/nattable/generic/tests/bugs/StereotypeSubPackagesDisplayTest.java new file mode 100644 index 00000000000..edd83bbc558 --- /dev/null +++ b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/src/org/eclipse/papyrus/uml/nattable/generic/tests/bugs/StereotypeSubPackagesDisplayTest.java @@ -0,0 +1,142 @@ +/***************************************************************************** + * Copyright (c) 2016 CEA LIST and others. + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the Eclipse Public License v1.0 + * which accompanies this distribution, and is available at + * http://www.eclipse.org/legal/epl-v10.html + * + * Contributors: + * Nicolas FAUVERGUE (ALL4TEC) nicolas.fauvergue@all4tec.net - Initial API and implementation + * + *****************************************************************************/ + +package org.eclipse.papyrus.uml.nattable.generic.tests.bugs; + +import java.util.List; + +import org.eclipse.papyrus.infra.core.sashwindows.di.service.IPageManager; +import org.eclipse.papyrus.infra.nattable.common.editor.NatTableEditor; +import org.eclipse.papyrus.infra.nattable.manager.table.INattableModelManager; +import org.eclipse.papyrus.infra.nattable.model.nattable.Table; +import org.eclipse.papyrus.infra.nattable.model.nattable.nattableaxis.FeatureIdAxis; +import org.eclipse.papyrus.junit.framework.classification.tests.AbstractPapyrusTest; +import org.eclipse.papyrus.junit.utils.TableUtils; +import org.eclipse.papyrus.junit.utils.rules.PapyrusEditorFixture; +import org.eclipse.papyrus.junit.utils.rules.PluginResource; +import org.eclipse.ui.IEditorPart; +import org.eclipse.uml2.uml.Model; +import org.junit.Assert; +import org.junit.Before; +import org.junit.Rule; +import org.junit.Test; + +/** + * This allows to test the stereotype properties available in sub packages in the table. + */ +@PluginResource("resources/bugs/bug488082/488082.di") +public class StereotypeSubPackagesDisplayTest extends AbstractPapyrusTest { + + /** + * The table name. + */ + private static final String TABLE_NAME = "GenericTable0"; //$NON-NLS-1$ + + /** + * The papyrus fixture. + */ + @Rule + public final PapyrusEditorFixture fixture = new PapyrusEditorFixture(); + + /** + * Constructor. + */ + public StereotypeSubPackagesDisplayTest() { + super(); + } + + /** + * This allow to initialize the tests. + */ + @Before + public void init() { + final Model model = (Model) fixture.getModel(); + Assert.assertNotNull("RootModel is null", model); //$NON-NLS-1$ + + // Get the table and open it + Table mainTable = TableUtils.getNotationFirstTable(fixture.getModelSet(), TABLE_NAME); + fixture.getPageManager().openPage(mainTable); + fixture.flushDisplayEvents(); + } + + /** + * This allows to test the stereotype inherited properties displayed in the table + * + * @throws Exception + * The caught exception. + */ + @Test + public void testStereotypePropeties() throws Exception { + // Open the table and get the manager + final IPageManager pageManager = fixture.getPageManager(); + final List<Object> pages = pageManager.allPages(); + pageManager.openPage(pages.get(0)); + final IEditorPart part = fixture.getEditor().getActiveEditor(); + Assert.assertTrue(part instanceof NatTableEditor); + final NatTableEditor editor = (NatTableEditor) part; + final INattableModelManager currentManager = (INattableModelManager) editor.getAdapter(INattableModelManager.class); + Assert.assertTrue(currentManager instanceof INattableModelManager); + + checkTableContent(currentManager); + } + + /** + * This allows to test the table cell editors and values. + * + * @param currentManager + * The current nattable model manager. + * @throws Exception + * The caught exception. + */ + protected void checkTableContent(final INattableModelManager currentManager) throws Exception { + // check the rows and columns number + Assert.assertEquals("The rows number is not the expected one", 1, currentManager.getRowCount()); //$NON-NLS-1$ + Assert.assertEquals("The columns number is not the expected one", 6, currentManager.getColumnCount()); //$NON-NLS-1$ + + final List<Object> columns = currentManager.getColumnElementsList(); + + // Check the first column + Assert.assertTrue("The first column must be a feature id axis", columns.get(0) instanceof FeatureIdAxis); //$NON-NLS-1$ + Assert.assertEquals("The first columns must be the first attribute", "property_of_stereotype:/RootElement::Package1::Profile1::Stereotype1::Attribute1_1", ((FeatureIdAxis) columns.get(0)).getElement()); //$NON-NLS-1$ //$NON-NLS-2$ + + // Check the second column + Assert.assertTrue("The second column must be a feature id axis", columns.get(1) instanceof FeatureIdAxis); //$NON-NLS-1$ + Assert.assertEquals("The second columns must be the first attribute", "property_of_stereotype:/RootElement::Package1::Profile1::Stereotype1::Attribute1_2", ((FeatureIdAxis) columns.get(1)).getElement()); //$NON-NLS-1$ //$NON-NLS-2$ + + // Check the third column + Assert.assertTrue("The third column must be a feature id axis", columns.get(2) instanceof FeatureIdAxis); //$NON-NLS-1$ + Assert.assertEquals("The third columns must be the first attribute", "property_of_stereotype:/RootElement::Package1::Stereotype2::Attribute2_1", ((FeatureIdAxis) columns.get(2)).getElement()); //$NON-NLS-1$ //$NON-NLS-2$ + + // Check the fourth column + Assert.assertTrue("The fourth column must be a feature id axis", columns.get(3) instanceof FeatureIdAxis); //$NON-NLS-1$ + Assert.assertEquals("The fourth columns must be the first attribute", "property_of_stereotype:/RootElement::Package1::Stereotype2::Attribute2_2", ((FeatureIdAxis) columns.get(3)).getElement()); //$NON-NLS-1$ //$NON-NLS-2$ + + // Check the fifth column + Assert.assertTrue("The fifth column must be a feature id axis", columns.get(4) instanceof FeatureIdAxis); //$NON-NLS-1$ + Assert.assertEquals("The fifth columns must be the first attribute", "property_of_stereotype:/RootElement::Package1::Package1_1::Stereotype3::Attribute3_1", ((FeatureIdAxis) columns.get(4)).getElement()); //$NON-NLS-1$ //$NON-NLS-2$ + + // Check the sixth column + Assert.assertTrue("The sixth column must be a feature id axis", columns.get(5) instanceof FeatureIdAxis); //$NON-NLS-1$ + Assert.assertEquals("The sixth columns must be the first attribute", "property_of_stereotype:/RootElement::Package1::Package1_1::Stereotype3::Attribute3_2", ((FeatureIdAxis) columns.get(5)).getElement()); //$NON-NLS-1$ //$NON-NLS-2$ + + // Check the values + Assert.assertEquals("The first value is not the expected one", true, currentManager.getDataValue(0, 0)); //$NON-NLS-1$ + Assert.assertEquals("The second value is not the expected one", "Test1", currentManager.getDataValue(1, 0)); //$NON-NLS-1$ //$NON-NLS-2$ + Assert.assertEquals("The third value is not the expected one", 2, currentManager.getDataValue(2, 0));//$NON-NLS-1$ + Assert.assertEquals("The fourth value is not the expected one", "Test2", currentManager.getDataValue(3, 0)); //$NON-NLS-1$ //$NON-NLS-2$ + Assert.assertEquals("The fifth value is not the expected one", 3.14, currentManager.getDataValue(4, 0)); //$NON-NLS-1$ + Assert.assertEquals("The sixth value is not the expected one", "Test3", currentManager.getDataValue(5, 0)); //$NON-NLS-1$ //$NON-NLS-2$ + + } + +} diff --git a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/src/org/eclipse/papyrus/uml/nattable/generic/tests/tests/AllTests.java b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/src/org/eclipse/papyrus/uml/nattable/generic/tests/tests/AllTests.java index b85efd41d11..fc58e232ae0 100755 --- a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/src/org/eclipse/papyrus/uml/nattable/generic/tests/tests/AllTests.java +++ b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/src/org/eclipse/papyrus/uml/nattable/generic/tests/tests/AllTests.java @@ -10,6 +10,7 @@ * Contributors: * Vincent Lorenzo (CEA LIST) vincent.lorenzo@cea.fr - Initial API and implementation * Quentin Le Menez (CEA LIST) quentin.lemenez@cea.fr + * Nicolas FAUVERGUE (ALL4TEC) nicolas.fauvergue@all4tec.net * *****************************************************************************/ package org.eclipse.papyrus.uml.nattable.generic.tests.tests; @@ -24,6 +25,7 @@ import org.eclipse.papyrus.uml.nattable.generic.tests.bugs.InvertedAxisChangeInd import org.eclipse.papyrus.uml.nattable.generic.tests.bugs.InvertedAxisChangeIndexWithoutConfigurationTest; import org.eclipse.papyrus.uml.nattable.generic.tests.bugs.OpenAndDeleteTest; import org.eclipse.papyrus.uml.nattable.generic.tests.bugs.StereotypeInheritDisplayTest; +import org.eclipse.papyrus.uml.nattable.generic.tests.bugs.StereotypeSubPackagesDisplayTest; import org.eclipse.papyrus.uml.nattable.generic.tests.importfile.ImportCellsAll_Test; import org.eclipse.papyrus.uml.nattable.generic.tests.importfile.ImportEmptyAddAll_Test; import org.eclipse.papyrus.uml.nattable.generic.tests.importfile.ImportEmptyReplaceAll_Test; @@ -85,16 +87,19 @@ import org.junit.runners.Suite.SuiteClasses; FilterNumericMatcherTest.class, FilterUMLEnumerationMatcherTest.class, CellEditorsConfigurationTest.class, - + // Stereotype inherited properties StereotypeInheritDisplayTest.class, - + + // Stereotype properties in sub packages + StereotypeSubPackagesDisplayTest.class, + // Check the enumeration content items EnumerationContentItemsTest.class, // Paste Overwrite tests PasteEmptyClipboard_Test.class, - + PasteCellsOverwriteAll_Test.class, PasteCellsOverwriteByOneLine_Test.class, PasteCellsOverwriteFailColumns_Test.class, @@ -120,7 +125,7 @@ import org.junit.runners.Suite.SuiteClasses; // Insert tests InsertEmptyClipboard_Test.class, - + InsertRowsReplaceAll_Test.class, InsertRowsAddAll_Test.class, InsertRowsSkipAll_Test.class, |