uml and design patterns
Object Oriented Analysis OOA
Object-Oriented Analysis Model and Procedure
- Detailed Explanation of UML Class Diagram
Through the above diagram, I have an overall understanding of UML. Next, I will give you a detailed introduction to the following relationships in the UML class diagram:
Generalization: Graphics are hollow triangles + solid lines
Realization: Graphics are hollow triangles + dotted
lines Association: Graphics are arrows + solid lines
Combination: Graphics are solid diamonds + solid arrows
Aggregation: Graphics are hollow diamonds + arrows
Dependency: Graphics are arrows + dotted line
class-to-class relationships
The relationship between classes can be divided into the following five types according to the strength of the relationship:
----依赖关系(Dependency)
---关联关系(Association)
---聚合(Aggregation)
---组合(Composition)
---泛化(Generalization)
依赖关系是五种关系中耦合最小的一种关系。
1. Association relationship:
1.1. Aggregation relationship:
1.2. Composition relationship:
2. Dependency relationship:
3. Pan-China relationship:
4. Realization relationship:
Use the UML class diagram to draw the relationship between the three of them.
Design Patterns
###Design pattern classification
According to the creation of a class or object design pattern is divided into
1. Creational mode
### Only produce one product at a time
Multiple products can be produced:
2. Structural model
------------------- Handle the combination of classes and objects
(It's two different classes working together, phone charger)
insert image description here
3. Behavioral mode [describes how classes and objects interact and mutual responsibilities]
insert image description here