We’ve received feedback as below:
“I’m satisfied with Astah so far. It’s intuitive and easy to use. One of the improvements is to provide default button for interface and abstract class (instead of putting stereotype to define interface and abstract class). Or maybe I miss this button.”
How to create Interface
Actually there is a default button to create Interface. Let’s open a Class diagram and see the tool bar there. There is a button to create Interface in Class notation directly.
Select “Interface [Normal]” then click on the diagram, an Interface will be created.
How to define abstract
You can go to the Class’s Property view and specify it as abstract or not in its [Base] tab. After setting the Abstract as “true”, the Class name will be shown in italic.
You may know this already but you can add the stereotype from Class’s property view as well.
1. Create a Class and open its Property View
2. Go to [Stereotype] tab and then click [Add]
3. A list of stereotype appears, select “abstract”.
2 thoughts on “How to create Interfaces”
Would like to see you add a UML type that works well for Traits/Roles/Mixins (basically an interface + implementation ) currently of course this is the best.
Thank you for your comment. 🙂
Currently and technically there are no modern concepts as you mentioned in UML itself.
This isn’t a convenient nor perfect solution, but you can use “stereotypes”, “interfaces”, “abstract classes” and other constructs to express what you need to implement.
For instance, I would personally use an “abstract” class for a (scala-like)trait with a trait stereotype, and use generalizations (multiple inheritance) to mixin them into a class.