Get the App
SLTechnology News&Howtos  ›  Internet Technology  › 

A lesson in OO Design patterns: abstract factories

Shulou Source: shulou.com Published: 2022-06-03 06:48:12 10月03日 Update

Scene and intention

Scene: multi-theme / style

Intention: to provide a loosely coupled and scalable design for managing product families

Characteristics

Isolate the actual users of the product from the specific implementers of the product, so that the expansion of the product family does not affect the user code

The use of product families is dynamic, and it can be dynamic.

Design structure

Demo

Https://github.com/zhanglong1/DesignPatternsJava

Tags: Product family design product user dynamic scene intention theme code implementer reality feature structure style switch influence management coupling factory pattern Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Shulou Information Docker Redmi vpn Linux