{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

5 - UML Class Diagrams Sometimes called static structure...

Info iconThis preview shows pages 1–8. Sign up to view the full content.

View Full Document Right Arrow Icon
UML Class Diagrams Sometimes called static structure diagrams May also contain interfaces, objects, and relationships Unified Modeling Language (UML), version 2.1.2 Examples taken from UML Reference Manual
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Classes Every behavior a system provides should be associated with a class Candidate for classes include domain objects, roles, events, and interactions A class is denoted by a rectangle (or an icon) and normally contains three, vertically stacked, compartments – Name – Attributes – Operations – (Responsibilities, exceptions, etc. )
Background image of page 2
Name Compartment Stereotype, if any – Extra, meta-model-defined labels – Enclosed by «» (guillemets) • Name – Should be a noun – Italics for abstract classes Properties in braces –{abstract}, {leaf}, {root}
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Example Class
Background image of page 4
Class Features Classes have features (attributes and operations) While objects and classes exist in the real world or in the mind of the designer, features exist inside of the computer • An attribute is a property of a class – Typically, attributes have types that correspond to primitive or composite data types available on the computer • An operation (method) is a service provided by an object. It may take typed parameters and possibly return a typed value
Background image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Attributes Visibility – + (public), - (private), # (protected), ~ (package) Name Optional multiplicity and ordering Type Initial value Derivation ( / ) Properties Class scope (underlining) – {frozen}, {changeable}, {addOnly}
Background image of page 6
Operations Visibility Name
Background image of page 7

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Image of page 8
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}