[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[news.eclipse.tools.uml2] Re: Stereotypes loosing their base classes?

The following sequence leads to the problem I mentioned. Hopefully you'll 
find what I'm doing wrongly.

1. Create a new profile (say p.profile.uml)
2. Set 'p' as the name of the Profile root element
3. Create a child Package Element Stereotype element
4. Give it the name 's'
5. Make the brand new profile to reference the metaclass uml::Class
6. Create an extension for the stereotype 's' to uml::Class
7. Define the profile.

8. Create a new model (say m.uml)
9. Create a child Package Element Class element
10. Load resource p.profile.uml from workspace
11. Apply profile p to the brand new model
12. Apply stereotype p::s to the new Class
13. Save and close the model

14. Open p.profile.uml again
15. Delete element p (child of "<Profile> p -> UML")
16. Redefine profile p
17. Open the model (m.uml) again


I believe the problem is the way I redefine de profile (steps 15 and 16). 
The problem persists regardless I unapply and reapply the profile.

Regards,
-- 
Ricardo Giacomin



"James Bruck" <jbruck@xxxxxxxxxx> wrote in message 
news:eggcu7$c14$1@xxxxxxxxxxxxxxxxxxxx
> If the profile has been changed in a significant way, I believe you would
> have to redefine your profile ( ie create a new EPackage representation )
> and then reapply your profile to your model, then re-open.  From my
> understanding, when you apply your profile, you are really referring to 
> the
> EPackage representation created in the profile as a result of defining it.
> If you then start changing your profile, stereotypes etc, your EPackage
> could get out of sync.  ( it would depend on the kinds of changes you
> make ).  Kenn is the expert on profiles but that is my understanding.
>
> Did you try to redefine then reapply?
>
> - James.
>
> "Kenn Hussey" <khussey@xxxxxxxxxx> wrote in message
> news:eggbk7$3lq$1@xxxxxxxxxxxxxxxxxxxx
>> Ricardo,
>>
>> Did you do anything to your profiles (in addition to adding new
> stereotypes)
>> other than redefine them (e.g. removing any annotations or stereotypes)?
> If
>> you can post your models (or a representative sample), we'll try to find
> out
>> what is going wrong...
>>
>> Kenn
>>
>> "Ricardo Giacomin" <giacomin@xxxxxxxxxxxxx> wrote in message
>> news:egecge$q6k$1@xxxxxxxxxxxxxxxxxxxx
>> > Hi,
>> >
>> > Please refer to the image in attachment.
>> >
>> > There are 2 profiles (mad and mad.ui) applied to the gpao.uml model. I
>> > applied the stereotypes in these profiles to the classes in the model.
> For
>> > instance, the 3 selected classes had the <<Page>> stereotype. Everthing
>> > worked fine in the first time I created and saved the model. After
> closing
>> > the document, I changed the profiles to include more stereotypes and
>> > redefined the profiles. Since then, when I open the document the
>> > stereotypes seem to not refer to the classes anymore (the attached
> picture
>> > depicts the problem).
>> >
>> > The symptom seems to be the same as reported by Laco (see thread "model
>> > with stereotypes applied not saved correctly", on 10/3): all applied
>> > stereotypes are displayed as children of root element and not the
> classes
>> > which they were applied to (however, i'm not working programmatically
>> > neither have defined the prototype twice).
>> >
>> > Any help would be appreciated.
>> >
>> > Regards,
>> > -- 
>> > Ricardo Giacomin
>> >
>> >
>> >
>>
>>
>
>