Design pattern (Design pattern) is a set of classified and cataloged summary of code design experience that is used repeatedly, known to most people. The purpose of using design patterns is to reuse code, make the code easier to understand by others, and ensure code reliability. There is no doubt that design patterns are win-win for ourselves, others, and the system; design patterns make code writing truly engineering; design patterns are the cornerstone of software engineering, just like the structure of a building. We have collected the "Boolean Educational Design Pattern Video Tutorial", hoping to help everyone better understand the concept of design patterns.
Course playback address: http://www.php.cn/course/292.html
The teacher’s teaching style:
The teacher’s lectures are simple, clear, layer-by-layer analysis, interlocking, rigorous argumentation, rigorous structure, using the logical power of thinking to attract people Students' attention and rational control of the classroom teaching process. By listening to teachers' lectures, students not only learn knowledge, but also receive thinking training, and are also influenced and influenced by teachers' rigorous academic attitude.
The more difficult point in this video is the bridge mode:
Bridge mode: In a software system, some types have two or more types due to their own logic. How to deal with this "multi-dimensional change"? This requires using the bridge pattern - separating the abstract part from its implementation part so that they can change independently.
Role introduction:
Abstraction (AbstractRoad) role: Abstract the definition given and save a reference to the implementation object.
Modify the abstraction (SpeedWay) role: extend the abstraction role, change and modify the definition of abstraction by the parent class.
Implementation (AbstractCar) role: This role provides an interface to implement the role, but does not give a specific implementation. It must be pointed out that this interface is not necessarily the same as the interface definition of the abstract role. In fact, the two interfaces can be very different.
Specific Implementation (Bus) role: This role gives the specific implementation of the character interface.
Here we also recommend downloading the source code resources: http://www.php.cn/xiazai/learn/2131
The resources are shared with you. Video courseware and source code
The above is the detailed content of Recommended courseware source code for Boolean educational design pattern video tutorials. For more information, please follow other related articles on the PHP Chinese website!