1 class diagram
(1) UML arrow direction: From the child class to the parent class. You need to pass the extends keyword when defining a subclass, so the subclass must know the parent but the parent does not know the subclass.
(2) Hollow triangle + solid line: inheritance; dotted line: implementation. Hollow triangle: inheritance or realization. The solid line table inheritance is very strong; the dotted line is more imaginary but simply implements an interface.
p>
(3) Arrow + solid line: association, +dashed line: dependent. Solid line: The relationship is relatively stable, and the association relationship usually has another class as an attribute in one class. Dotted line: For temporary use, generally one class uses another class as a parameter or return value.
(4) Hollow diamonds: aggregation, solid: combination. Rhombus: Represents an empty container. A hollow is that many of the same things are put together, so they are aggregated together, and the life cycle of each individual entity inside can be different. Solid: The relationship is relatively strong, life and death are shared, and they form a whole, and the internal life cycle is the same.
p>
As shown in the picture below for the combination:
The combination in the figure above can be considered as a bird containing two instances of wings.
2 Timing diagram
3 Specific class diagrams
+: public –: private # strong>: protected ~: default (package permissions) Underscore: static. Note that the study() in the method is italicized to indicate the abstract method, so there is a small error method should also be abstract method should also be italicized. Method name: Type, which indicates the type of return value.
4 types of relationships
p>
>
< p>
< /p>
p>
>
< p>0