Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Hendrik Jan van Randen

Pages: [1]
1
When I search the EA documentation for _metaclass it says 'No topics found'.

2
The type of the tagged value definition can't be an 'ordinary' class. It should be a metaclass, to indicate to which elements (being instances of that metaclass) the corresponding tag (in elements on which the stereotype is applied) can refer.

It's not clear to me what you (David) mean with "add a _metatype attribute to the MyClass entity with a value of Class".

Instead of searching a workaround, I think that it would be much more efficient to resolve this problem in the product, thus if a stereotype property type is a metaclass, let the behavior of the corresponding tagged value follow that stereotype property type definition and multiplicity. In several other products for which we're evaluating whether they can become our standard (Rational Software Modeler, MagicDraw and Borland Together) this works fine. To keep Enterprise Architect competing it is really necessary to fix this.

If you have a developer build of Enterprise Architect in which this is fixed, I would be very glad to test it and to provide feedback.

Hendrik Jan

3
The picture suggested above requires that each referred class has a stereotype (in the picture stereotype «myClass»). That's not desired (and it is the workaround that I mentioned in the P.S. of my original posting
http://www.sparxsystems.com/cgi-bin/yabb/YaBB.pl?board=UMLPRO;action=display;num=1192546905
).

The required picture is:

4
Suggestions and Requests / please act on stereotype property type metaclass
« on: November 06, 2007, 12:32:25 am »
subject: If stereotype property type is metaclass, please let corresponding tagged value follow that definition

dear makers of Enterprise Architect,

I've defined a stereotype «maintains» which extends metaclass 'Use Case'.
On this stereotype I've defined property 'maintainedClass', of which the type is metaclass 'Class', with multiplicity 1..*.

When I apply this stereotype to a use case, I would expect that in that use case for its tagged value 'maintainedClass' in the value field I can select one or more classes that I've defined in the same model.
Instead, in its value field I can type any text, as if the type of the defined property is 'string', and I cannot select any class for it.

To a certain extent this problem can be worked around by manually editing a tagged value type, the profile export file and by writing an add-in, as described in the reponses to my post on the UML Process forum
http://www.sparxsystems.com/cgi-bin/yabb/YaBB.pl?board=UMLPRO;action=display;num=1192546905

Those workarounds are too cumbersome to be practically applicable if a profile has many such properties.

Can you please, if a stereotype property type is a metaclass, let the behavior of the corresponding tagged value follow the stereotype property type definition and multiplicity?

with kind regards,

Hendrik Jan van Randen
Solution Architect
Atos Origin

5
Uml Process / Re: Stereotype property not visible when apply pro
« on: November 23, 2007, 09:01:57 am »
Thank you, that works fine!

Hendrik Jan

6
Uml Process / Stereotype property not visible when apply profile
« on: November 22, 2007, 08:31:16 am »
dear all,

When I define a profile with a stereotype and a property on that stereotype, and I import this profile into another project, I don't see that property.

The exact steps that I executed are:
1. Start Enterprise Architect
2. File : New Project..., File name = hjsProfile.eap, click Save, click OK
3. In Project Browser right click Model, New View..., Name=hjsView, click OK
4. In Project Browser Expand Model, double click hjsView, right of Stereotype click …, click New…, type profile, click OK, click OK, click OK
5. In Project Browser right click hjsView, Add : Add Diagram, Name = hjsDiagram, click OK
6. In Toolbox click More tools..., UML : Profile
7. In Toolbox (under Profile Elements) click Metaclass, click canvas, in dialog in Element list check UseCase, click OK
8. In Toolbox (under Profile Elements) click Metaclass, click canvas, in dialog in Element list check Class, click OK
9. In Toolbox (under Profile Elements) click Stereotype, click canvas, Name = maintains, click OK
10. In Toolbox (under Profile Relationships) click Extension, in diagram drag from stereotype maintains to metaclass UseCase
11. In the diagram right click stereotype maintains, choose Attributes...:
  a. Click New
  b. Name = maintainedClasses
  c. In the Type dropdown choose Class
  d. In Scope dropdown choose Public
  e. Click Save
  f. Click tab Detail, Lower bound = 1, Upper bound = *, click Save, click Close
12. ctrl-s
13. In Project Browser right click package hjsView, Save Package as UML Profile, Filename = hjsProfile.xml, click Save

14. File : New Project..., File name = useHJsProfile.eap, click Save, Click OK
15. Click tab Resources, and then in it:
  a. Right click UML Profiles, Import Profile
  b. Right of Filename click ..., double click hjsProfile.xml, click Import
16. Click tab Project Browser, and then in it:
  a. Right click Model, New View..., Name = hjsUsingView, click OK
  b. Expand Model, right click hjsUsingView, Add : Add Diagram..., Name = hjsUsingDiagram, click OK
17. In Toolbox click Class, click Canvas, Name = Order, OK
18. In Toolbox click More tools..., UML : Use Case
19. In Toolbox click Use Case, click Canvas, Name = maintainsOrders, in Stereotype dropdown select maintains, click OK
20. ctrl-s

Problem: In the Properties pane I don't see property maintainedClasses, and in the Tagged Values pane I don't see it either.

What should I do to make this property visible?

Thanks,

Hendrik Jan


P.S. In earlier experiments I did see the property, but at that time I didn't write down the exact steps that I had taken, and now I don't succeed in finding out which those steps were... :-(

7
Uml Process / Re: If stereotype property type is metaclass, how
« on: October 22, 2007, 11:40:19 pm »
Thank you all for your suggestions! I've done some experiments, which show the following concerning point 1:

> In your profile, give the <<stereotype>> element an
> attribute with the same name as the tagged value type

Giving the stereotype a «tagged value» relationship with the same name brings the tagged value to the export file (an attribute doesn't).
This however doesn't export the details field of the tagged value type from the UML Types. I can workaround that by copy-pasting "Type=Classifier;Stereotypes=persistent;" from that details field into the notes attribute in the export xml file, but that is (of course) overwritten when I re-export the profile (e.g. after adding new stereotypes to it).

All together it would be a lot easier if issues 1, 2 and 3 would all be derived automatically from the stereotype attribute type and multiplicity, now it is a lot of manual work.

8
Uml Process / Re: If stereotype property type is metaclass, how
« on: October 18, 2007, 03:06:02 am »
Thank you for your suggestion, this works fine to a certain extent if I define such a tagged value type in the project in which I want to apply the mentioned stereotype.

However, the following issues remain:

1. In this way I have to redefine this tagged value type (and my other similar tagged value types) manually in each project in which I want to apply my profile. That's too much repeating work. How can I define such tagged value types in my profile project, so that they can be exported and imported with the profile? (If I define the tagged value types in my profile project, and export-import the profile to another project, the tagged value types are currently not available in that other project.)

2. How can I restrict the elements on which users can give this tag a value? (In my example I want to restrict that to «crud» use cases.)

3. How can I, for the elements (in the example «crud» use cases) on which this tagged value type applies, show the tag automatically in the Tagged Values pane? Now users for each «crud» use case have to click the 'New Tag' button and select the 'maintains' tag from a long list of possible tags.

These issues would all be resolved if the type and multiplicity of the stereotype-property-definition described in the first paragraph of my original scenario would result in a corresponding tagged value type definition in the projects that use (thus import) the profile. What can I do to accomplish that?

with kind regards,

Hendrik Jan van Randen

9
Uml Process / If stereotype property type is metaclass, how ...
« on: October 16, 2007, 06:01:45 am »
Subject: If a stereotype property type is a metaclass, how can you for its tagged value select instances of that metaclass?


dear all,

I've defined a stereotype «crud» which extends metaclass 'Use Case'.
On this stereotype I've defined property 'maintains', of which the type is metaclass 'Class', with multiplicity 1..*.

When I apply this stereotype to a use case, I would expect that for the tagged value 'maintains' I can select one or more classes that I've defined in the same model.
Instead, in its value field I can type any text, as if the type of the defined property is 'string', and I cannot select any class for it.

What should I do to be able to select one or more classes for this property? I'm using Enterprise Architect version 7.0.817.

Hendrik Jan


P.S. To a certain extent a workaround is to define a stereotype «x» which extends metaclass 'class', and to define a 'tagged value' relationship named 'maintains' from «crud» to «x», with target role multiplicity 1..*.
However, this workaround has the following disadvantages:
1. For the tagged value 'maintains' you can select only one class, thus the multiplicity definition is apparently ignored.
2. It is ugly and inconvenient that you have to apply stereotype «x» to a class in order to make it selectable in the 'maintains' property.

Pages: [1]