Viewing Types and Relationships on Class Diagrams

The Visual Studio Class Designer uses a diagram to show you the details of types, their constituent members, and the relationships they share. Your visualization of these entities is actually a view into the code. This means that, for types that are read/write, you can edit them and then see your edits when you view the source code of the entity. Similarly, a class diagram is kept synchronized with changes you make to entities in code.

Note

If your project contains a class diagram and references a type that exists in another project, the class diagram does not show the referenced type until you build the project for that type. Likewise, the diagram does not display changes to the code of the external entity until you rebuild the project for that entity. For information about entities in referenced assemblies and read-only files, see Display of Read-Only Information.

In This Section

Understanding Code You Did Not Write

Describes how the Class Designer can be used to visualize pre-existing code.

How to: View Existing Types

Explains how to visualize existing types in the class designer.

How to: View Compartments in Type Shapes

Describes how to view compartments in type shapes.

How to: View Type Members

Explains how to view type members in the Class Diagram

How to: Group Type Members

Describes how to group members of types in the Class Designer.

How to: View Type Details

Explains how to view a type's details.

How to: View Inheritance Between Types

Describes how to view the inheritance relationships between types.

How to: View Derived Types

Explains how to view types derived from a particular base type.

How to: Change Between Member Notation and Association Notation

Describes how to switch between member notation and association notation.

Designing Classes and Types

Refactoring Classes and Types

Customizing Class Diagrams

Working with Class Diagrams