UML Elements

A UML project consists of UML elements organized into a tree-like structure. 

Examples of elements include packages, use cases, classes, relationships, activities, diagrams, and features.

Each parent node in a project "owns" its children. For example, a package owns its classes, a class owns its attributes and operations. An operation owns its parameters, etc.

A model is a package of elements representing some viewpoint of a system. For example, a requirements model contains use cases and represents the viewpoint of a customer, while a design model contains classes and represents the viewpoint of a developer.

UML diagrams are graph-like views of models. A model may have many views.

Visibility

Most UML elements have a name and a visibility:

+ = public (visible to all elements in the project)
- = private (only visible to siblings)
# = protected (visible to all specializations)
~ = package (visible to all elements in the same package)

Stereotypes, Tags, and Profiles

UML elements can also have constraints, stereotypes, and tags.

A stereotype is a meta-class that the element belongs to. It is often bracketed by guillemets:

<<actor>>, <<entity>>, <<trait>>

A tag is a stereotype attribute and thus a meta-property of elements having that stereotype.

A profile is a collection of reusable stereotypes, tags, and constraints.

For example, an engineering profile might contain the stereotype <<File>> with properties owner, permissions, extension, and path.

A class diagram might contain classes having the File stereotype and fixed values for some of its tags:

Constraints

A constraint is a Boolean-values property that must be satisfied. It is often shown as a comment bracketed by curly braces:

Officially, constraints should be expressions in the Object Constraint Language (OCL).

UML Meta-Model

UML is specified by the Object Management Group (OMG) using UML. Here's a simplified look at the UML meta-model.