UML Class DiagramsThe role of UML Class Diagrams in the forward engineering of object-oriented software systems is to model the static design view of a system. When applied to the reverse engineering an existing system, this same view offers the possibility of improved understanding. By mapping C++ and Java source code constructs to the underlying language-independent UML Class Diagram constructs, Imagix 4D is able to apply its comprehensive database to generate informative class diagrams. When combined with the ability to focus on specific areas of the software and to control the level of detail, these diagrams provide users a valuable tool for program comprehension and analysis.
As defined in the Unified Modeling Language standard, a class diagram shows a set of classes, interfaces, and collaborations and their relationships. These relationships include generalization, aggregation and association. Under C++ and Java, the classes, interfaces, and collaborations aligns directly with classes and templates. And both languages incorporate generalization via class inheritance. So at a starting level, the UML Class Diagram resembles a class inheritance hierarchy graph, where the diagram shows which classes inherit from which other classes. Aggregation aligns less directly with C++ and Java constructs. To generate information about aggregation relationships, Imagix 4D analyzes where a class is used as a type for a variable. The class container of such a variable becomes the aggregate while the class being used is the component. This analysis also tracks the multiplicity involved in such aggregations.