Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I make a flow diagram of my program

Tags:

java

I have a very large server program written in java. It was written by another developer who is no longer with the company and is very complex.

It is made up of 23 packages and I use eclipse.

What I want is a program that will take the source files of my program and create a kind of flow char for the functions. Start with the class that has main and follow it through which classes it calls in its constructor.

Basically I have learned that the program uses interfaces heavily and I want a visual representation of how the server functions instead of tracking through several four line function in interfaces before I get to the real processing function. a flow chart type thing would allow me to see where the function call would end up.

Does anyone know of any program available that could do this for me ?

I don't really mind what format the visual representation is in as long as it is easy to follow.

like image 664
Skeith Avatar asked Jul 18 '11 11:07

Skeith


2 Answers

This is what you are looking for:

http://www.objectaid.com/

like image 154
Edgar Velasquez Lim Avatar answered Oct 27 '22 01:10

Edgar Velasquez Lim


The sequence in any program of significant size is so complex that an automatic tool (if it existed) is of no use - too many trees, no forest.

It is reasonable to generate class diagrams and then manually prune them down and organize them to show the organization of the program as you discover it.

To see the real flow of the program, I recommend using debugger breakpoints and then a good profiler. Usually it's relatively easy to find a spot where something important happens - the question usually is "how does it get here?". Take notes; when you think you understand a flow well, make a diagram.

Another diagramming package that I like a lot is PlantUML. It's missing a lot of UML features, but it allows for very rapid creation of diagrams, with the concise source within the .java files, and included in the JavaDoc.

like image 36
Ed Staub Avatar answered Oct 26 '22 23:10

Ed Staub