Sunday, June 20, 2010

UML CLASS DIAGRAM

What is Class Diagram:

Class Diagram is the basic of UML. It describes classes (Class, its members, properties) and shows the relationships between them.

Notation used in Class Diagram:

+ - Public
- - Private
# - Protected

'has- a' Relationship:
----------------------
Open Diamond - Aggregation ( Contained object are more like a collection of things - Eg: Aircraft in a Airport)
Diamond (Filled ) - composition (Contained object are part of Containing Object - Eg: Engine in a car)

ArrowHead - 'is - a' relationship (i.e Inheritance)

Italicized - Abstract Class

Indicating the Number of Objects Another Object Has

1..n - the containing object can have min 1 to max n contained object
1..* - the containing object can have min 1 to any number of contained object
2 - the containing object can have 2 contained object

No comments: