1.BuilderMode
Definition: Separates the construction of a complex object from its representation so that the same build process can create different representations . [Construction and presentation separation, different representations of construction]
For example, a car is made up of many parts. Parts are different and assembled in different ways.
The difference from the abstract factory: in the builder model, there is a mentor who manages the builder, and the user is in contact with the mentor,
The instructor contacted the builder and finally got the product. That is, the construction model can enforce a process of construction in stages.
Usage scenarios:
1 . When creating complex objects, the algorithm should be independent of the parts of the object and how they are assembled. 2, when the construction process must allow the constructed object to have different representations .
2. Illustrations
java-design mode (created)-"builder mode"