Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to generate UML diagrams (especially sequence diagrams) from Java code?

How can I generate UML diagrams (especially sequence diagrams) from existing Java code?

like image 893
Jonathan Avatar asked Sep 09 '08 12:09

Jonathan


People also ask

Can you generate UML from code?

Umbrello is a free software tool that supports a code import feature that automatically generates UML Class diagrams from your imported code. Umbrello supports up to 20 languages between C, C++, Python, Javascript and Java.

Can Eclipse generate UML diagrams?

You can create UML project for any of your Java project in Eclipse.


1 Answers

ObjectAid UML Explorer

Is what I used. It is easily installed from the repository:

Name:     ObjectAid UML Explorer Location: http://www.objectaid.com/update/current 

And produces quite nice UML diagrams:

Screenshot

Description from the website:

The ObjectAid UML Explorer is different from other UML tools. It uses the UML notation to show a graphical representation of existing code that is as accurate and up-to-date as your text editor, while being very easy to use. Several unique features make this possible:

  • Your source code and libraries are the model that is displayed, they are not reverse engineered into a different format.
  • If you update your code in Eclipse, your diagram is updated as well; there is no need to reverse engineer source code.
  • Refactoring updates your diagram as well as your source code. When you rename a field or move a class, your diagram simply reflects the changes without going out of sync.
  • All diagrams in your Eclipse workspace are updated with refactoring changes as appropriate. If necessary, they are checked out of your version control system.
  • Diagrams are fully integrated into the Eclipse IDE. You can drag Java classes from any other view onto the diagram, and diagram-related information is shown in other views wherever applicable.
like image 71
Thomas Ahle Avatar answered Sep 30 '22 17:09

Thomas Ahle