Agent mode of design mode (structural type)

Before introducing the agent mode, the blogger wants to say something "out of the question". The blogger likes playing games, especially hero League, especially compression. The blogger's compression can be said to be "fantastic". The blogger's friends call the blogger "tuoersuo". In other words, although the blogg ...

Posted by HIV on Fri, 18 Feb 2022 02:14:21 +0100

Practical explanation of enterprise level project! First line Internet mobile architect NDK module development! Interview experience

start During the "golden three silver four" season, there are always many people looking for the same thing called "Mianjing". In fact, it is a specific question, and then sharpen their guns and "recite" the answer. If this is always the case, I believe your ability will not be improved, even if you work for three ...

Posted by noguru on Thu, 17 Feb 2022 21:35:37 +0100

Design pattern series -- strategy pattern

Tip: after the article is written, the directory can be generated automatically. Please refer to the help document on the right for how to generate it example Scenario: Shopping mall cashier software, the salesperson charges the customer according to the unit price and quantity of the goods purchased by the customer. 1, Knowledge point ...

Posted by herschen on Thu, 17 Feb 2022 20:12:01 +0100

Design pattern | factory pattern (simple factory, factory method, abstract factory)

catalogue Simple factory Factory method Abstract factory Learning factory mode requires relevant inheritance and polymorphism knowledge such as C + + virtual function and pure virtual function Simple factory In simple factory mode, different instances can be returned according to different parameters.. The simple factory pattern specific ...

Posted by molave on Thu, 17 Feb 2022 13:08:03 +0100

Factory mode of design mode

Factory mode And Singleton mode Similarly, the factory pattern also belongs to a kind of creative design pattern. Singleton mode is used to ensure that there is only one instance of a class, while factory mode is used to create different objects related to types. It also has different implementation methods. It can be subdivided into simple fa ...

Posted by intodesi on Thu, 17 Feb 2022 10:38:31 +0100

Daily learning - Java design principles (Day4) - opening and closing principles

We must put forward such tasks for ourselves: first, learning, second, learning, and third, learning. There is never a shortcut to learning. You can reach the peak step by step. Some of the notes come from the video teaching of design mode in Silicon Valley. 1, Basic introduction Open Closed Principle is the most basic and important ...

Posted by rolwong on Wed, 16 Feb 2022 04:21:50 +0100

[design pattern] Template Method

Template Method It is recommended to read the directory of C + + design patterns motivation In the process of software construction, for a task, it often has a stable overall operation structure, but each sub step has many change requirements, or it can not be realized at the same time with the overall structure of the task due to inherent r ...

Posted by footbagger on Tue, 15 Feb 2022 13:10:25 +0100

Design pattern correlation

1, Design mode 1. Six principles 1. [single principle]: a class or method is only responsible for one responsibility 2. [Richter substitution principle]: subclasses can extend the functions of the parent class, but cannot change the functions of the original parent class 3. [dependency inversion principle]: interface oriented programming (r ...

Posted by dror_israel on Tue, 15 Feb 2022 05:30:45 +0100

[design mode] simple factory mode

Wechat search: Menon StayUp Home address: https://gozhuyinglong.github.io Source code sharing: https://github.com/gozhuyinglong/blog-demos Simple Factory Pattern is a simple implementation of factory pattern. It belongs to creation pattern. There is only one "factory" class in the Simple Factory Pattern, which can create diffe ...

Posted by foyer on Mon, 14 Feb 2022 02:03:05 +0100

Understand the decorator mode

When learning the classic design pattern, the decorator pattern is really a headache, but it is not difficult to realize after mastering its basic idea. First of all, the decorator has told us two basic information Something to be decorated can be seen as a coreThings with decoration can be regarded as different properties or functions It' ...

Posted by jamesnkk on Sun, 13 Feb 2022 21:30:55 +0100