Book a Demo

Author Topic: Stereotype empty in EA10 when creating objects  (Read 4821 times)

Kaspatoo

  • EA Novice
  • *
  • Posts: 19
  • Karma: +0/-0
    • View Profile
Stereotype empty in EA10 when creating objects
« on: November 13, 2014, 09:52:34 pm »
Hi,

I want to create objectinstances of classes via drag&drop from Project Browser into a diagram.

It then creates a object of that class. Fine.

The problem is, that the attributes stereotype and stereotypeEx are empty "".
The stereotype and stereotypeEx of the class are not empty.

I am Using EA 10.0.1005.

When my collegue is doing exactly the same on a copy of the EAP file stereotype and stereotypeEx of the instanciated object are equal to the stereotype and stereotypeEx of the class where the object is instanciated from.
My collegue is using EA 9.1.910

I would expect that this is a Bug.
Thats why I also did a Bug report.

But maybe someone knows any workaround or somthing else for this.

Thanks in advance.

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +397/-301
  • I'm no guru at all
    • View Profile
Re: Stereotype empty in EA10 when creating objects
« Reply #1 on: November 13, 2014, 10:10:38 pm »
This has changed from V10 on. I faintly remember someone from Sparx commenting on this (some Superstructure thing) but can't recall the details.

q.

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13523
  • Karma: +574/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Stereotype empty in EA10 when creating objects
« Reply #2 on: November 13, 2014, 10:48:21 pm »
The only workaround I can think of is to write an add-in that reacts to the creation of a new object and copies the stereotypes from the classifier to the object.

Should be no more then a half day of work.

Geert

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8110
  • Karma: +119/-20
    • View Profile
Re: Stereotype empty in EA10 when creating objects
« Reply #3 on: November 14, 2014, 08:42:35 am »
Simply put. If a stereotype says that it only applies to a Class, it can't be applied to an object. So, EA no longer copies it onto the object.

KP

  • EA Administrator
  • EA Expert
  • *****
  • Posts: 2919
  • Karma: +55/-3
    • View Profile
Re: Stereotype empty in EA10 when creating objects
« Reply #4 on: November 14, 2014, 08:59:09 am »
The _instanceType property (search help for details) can be used to define for a class stereotype what its corresponding instance stereotype should be.
The Sparx Team
[email protected]