Façade pattern
Many complex systems are reducible to just a couple of their use cases, exposed by the subsystems. By doing so, the client code does not need to know about the internals of the subsystem. In other words, the client code is decoupled from it and it takes less time for the developer to use it. This is known as a façade pattern, where the façade object is responsible for exposing all the subsystem's functionality. This concept resembles encapsulation, where we hide the internals of an object. With façade, we hide the internals of a subsystem and expose just the essentials. The consequence is that the user is limited to the functionality exposed by the façade, and is not able to use/reuse specific functionality from the subsystem. ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access