Model experience/understanding

Source: Internet
Author: User

1. Command mode: In short: Waiter-command-cook barbecue

2. Facade mode: the client can obtain many underlying class functions by dealing with only one class, for example, a class in the service can call some functions of many Dao classes in the DaO package. If the client wants to use these functions of these classes in the DaO package, you only need to deal with the service class.

3. Bridge Mode: allows the service package to have different classes with different functions, and also allows Dao to have different classes with different functions. To get different products, then assemble these different classes. For example, add a class in the service package to the parent class of some classes in the DaO package, then we can inject different Dao classes into this class of the service package to implement the Assembly principle.

4. Observer mode: The Observer pays attention to the target and puts the target in his mind. The target may take effect for a series of people who observe the target. Therefore, the observer list is saved. Once the target appears, the target allows the observer to update the observer's own status.

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.