Community
Participate
Working Groups
Created attachment 174483 [details] stacktrace I created an UML2 profile, following this tutorial: http://www.eclipse.org/modeling/mdt/uml2/docs/articles/Introduction_to_UML2_Profiles/article.html When I try to apply my profile by clicking on the UML2 editor's action "UML Editor > Package > Apply Profile..." (with my Model element selected in the editor), I get a ClassCastException (see attached stacktrace). I am using UML2 3.0.0.v201005031530 and Eclipse I20100527-1700.
Created attachment 174484 [details] my profile
Created attachment 174485 [details] the model I try to apply the profile on
How was the model you are trying to apply the profile to produced? Its reference to the definition of the standard profile looks suspicious: <profileApplication xmi:id="_09M-culsEd6OiOZfp0VQ5g"> <eAnnotations xmi:id="_09M-c-lsEd6OiOZfp0VQ5g" source="http://www.eclipse.org/uml2/2.0.0/UML"> <references xmi:type="ecore:EPackage" href="http://www.eclipse.org/uml2/schemas/Standard/1#/"/> </eAnnotations> <appliedProfile href="pathmap://UML_PROFILES/Standard.profile.uml#_0"/> </profileApplication> I would have expected the reference here (#/) not to be to the root element of the resource (i.e., the profile), but instead to the Ecore package defined within it (_yzU58YinEdqtvbnfB2L_5w).
This works for me using the latest UML2 4.0 build.