facade | - Create a special class, called a «Facade», which will simplify the use of the package.
- The «Facade» will contain a simplified set of public methods such that most other subsystems do not need to access the other classes in the package.
- The net result is that the package as a whole is easier to use and has a reduced number of dependencies with other packages.
- Any change made to the package should only necessitate a redesign of the «Facade»class.
| one of the Gang of Four patterns. | html>- Often, an application contains several complex packages.
- A programmer working with such packages has to manipulate many different classes
| html>- It is hard for a programmer to understand and use an entire subsystem - in particular, to determine which methods are public.
- If several different application classes call methods of the complex package, then any modifications made to the package will necessitate a complete review of all these classes.
| How do you simplify the view that programmers have of a complex package? | A pattern in which you create a class that provides a simplified interface to a package | 6.9 - The Facade Pattern | | design pattern |