Appendix B. UML Basics
Unified Modeling Language (UML) is an object modeling specification language that uses graphical notation to create an abstract model of a system. The Object Management Group governs UML. This modeling language can be applied to Java programs to help graphically depict such things as class relationships and sequence diagrams. The latest specifications for UML can be found at the OMG website. An informative book on UML is UML Distilled, Third Edition, by Martin Fowler (Addison-Wesley, 2003).
A class diagram represents the static structure of a system, displaying information for classes and relationships between them. The individual class diagram is divided into three compartments: name, attributes (optional), and operations (optional); see Figure B-1 and the example that follows it.
// Corresponding code segment
// Class Name
The name compartment is required and includes the class or interface name typed in boldface.
The attributes compartment is optional and includes member variables that represent the state of the object. The complete UML usage is as follows: