O'Reilly logo

Learning UML by Sinan Si Alhir

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Types, Implementation Classes, and Interfaces

The kinds of classes discussed thus far are known as undifferentiated classes, and are commonly used during design activities within a development process. You can also differentiate between three different kinds of classes, called differentiated classes. These include:

  • Types

  • Implementation classes

  • Interfaces

These differentiated classes closely relate to different activities in the development process. The next few sections discuss these differentiated classes.

Types

A type is a class that may have attributes, associations, and operations, but does not have any methods. A type defines a role an object may play relative to other objects, similar to how a rolename indicates the role a class plays relative to other classes in an association. For example, a Worker object may play the role of a project manager, resource manager, human resource, or system administrator. A type is shown as a class marked with the type keyword. These types of workers are shown in Figure 3-25.

Types

Figure 3-25. Types

Types are commonly used during analysis activities within a development process to identify the kinds of objects a system may require. You can think of types as conceptual classes, because they are ideas for possible classes. Also, because types do not have methods and represent roles only, they do not have instances.

Types may be used with binary and n-ary ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required