The Facade design patten provides a unified interface to a set of interfaces in a subsystem.This pattern defines a higher-level interface that makes the subsystem easier to use.
外观模式为子系统一组接口提供了统一的接口,这种模式定义了高级接口,便于子系统调用。
UML Class Diagram
Facade:
- Knows which subsystem classes are responsible for a requst
- Delegates client request to approciate subsystem objects.
Subsystem classes
- Implement subsystem functionality
- Handle work assigned by the Facade object.
- Have no knowlege of the facade and keep no reference to it.
When to use Facade Design Pattern in Real-Time Application?
- We want to provide a simple interface to a complex subsystem.
- There are many dependencies between clients and the implementation classes.
标签:subsystem,外观,use,模式,interface,classes,接口,Facade From: https://www.cnblogs.com/qindy/p/17412896.html