Submit a problem

In order to provide you the best help possible to analyze and debug your problems please provide us some information about your environment.
When you submit a problem, please indicate:
- The Version, Build Id, Core Id, System and Architecture (You can get these information in the Help/About menu entry)
- The Modelio Edition (Modelio Open Source or Modelio by Modeliosoft)
- Your Operating System

check [Solved] list stereotypes for an element?

1 week 3 days ago - 1 week 1 day ago #4511 by jsaluden
Hello,

I need some help in order to finish a little script...
Basically, the altgorithm is very simple: i reverse some tables via SQL module, i have to
1/ change the name (this point is ok),
2/ remove all stereotypes
3/ add mine (this point is ok)

I can't find a method to achive point 2? befor using removeStereotype() I need some "listStereotype()" or whatever its name is to list the stereotypes i have to remove.... But i can't find it...
Can somebody help me for this point?

Thanks
Yohann

Please Log in or Create an account to join the conversation.

1 week 3 days ago #4512 by jsaluden
Hello again,

Sorry, i was looking so hard for something as "xxxStereotype()" that i didn't see the getExtension() method...
I tried that, it works fine:

for s in element.getExtension():
nomM=s.getModule().getName();
nomS=s.getName();
print nomM+";"+nomS;
element.removeStereotypes(nomM,nomS);

Sorry,
Yohann

Please Log in or Create an account to join the conversation.

Moderators: chmcma
Time to create page: 0.047 seconds
^ Back to Top