Project proposal: Visualization of Software Structure

Group members: Reid Holmes, Andrew Chan

As software systems have grown more complex, programming languages have been created with features like information hiding, classes, inheritance, abstract classes, and interfaces. These features introduced structure into systems and abstracted implementation details, so that software developers could more readily understand how a system works. At the same time, modelling languages like UML have been developed to allow software designers to capture the intended structure of a system and how the different components in the system will interact.

While commercial tools are available to support the design process, they are often concerned with depicting the structure of the whole system in a static manner, showing all details at once. This approach fails when users want to ask specific questions about the code. It also fails to scale well to large systems. The ability to ask specific questions about the software structure is important when developers are trying to learn about a new or legacy code base in order to understand the code they are attempting to modify. The ability to scale is important because not all parts of the code are relevant to any particular operation and often views on the system will help developers to gain the important insights they need to accomplish their jobs.

We propose to build a system that will allow software developers to view the structure of their Java systems. It will likely present information in a UML-like diagram, showing packages, their classes, and the connections between them. To make this system scalable, we propose to use zooming so that a developer can abstract some parts of a system and focus on others. Another feature will be the ability to selectively elide connections between classes. This is important because it is common for classes to exist that are used heavily throughout the system, and this is to be expected. To reduce clutter, the connections to these classes can be safely ignored. The system will also support specific queries on the code base to allow developers to examine the call chain that invoking a method will execute. Furthermore, the elements in the graph structure we will work with will preserve linkages between the nodes and the code so that developers can always concretely see the context of the calls they are seeing in the visualization.

This project will also be the basis for our CPSC 507 (Software Engineering) course with Gail Murphy. The implementation language will be Java (hopefully). We plan to use existing software tools (either FEAT, JQuery, or Chava) to perform source code analysis, so that we can focus on the task of presenting the system structure in an effective manner. We will also rely on existing tools to draw the visualization; possible candidates are Piccolo, Tulip, Jazz, or ZVTM/ZVRGViewer which are freely available drawing packages.

  1. Visualize medium-sized system (eg. JEdit (100,000 loc ~200 classes))
    1. Package views
    2. Class structure
    3. Call structure
  2. Zooming functions to focus on particular nodes of interest
  3. Elision features to remove unwanted nodes / edges
  4. Allow the user to perform specific queries
    1. Fan-in queries:  Determin what methods/classes call a particular method/class
    2. Fan-out queries:  Determine what methods/classes a particular method/class calls
  5. Link nodes in visual structure to source code

Preliminary ideas of how the system would look: