Facade< Computer Science Design Patterns
A Facade pattern hides the complexities of the system and provides an interface to the client from where the client can access the system. Dividing a system into subsystems helps reduce complexity. We need to minimize the communication and dependencies between subsystems. For this, we introduce a facade object that provides a single, simplified interface to the more general facilities of a subsystem.
SCP command is a shortcut for SSH commands. A remote file copy could be done writing several commands with an SSH connection but it can be done in one command with
SCP. So the
SCP command is a facade for the SSH commands. Although it may not be coded in the object programming paradigm, it is a good illustration of the design pattern.
This pattern is very easy and has not additional cost.
This pattern is very easy to create.
This pattern is very easy to maintain.
This pattern is very easy to remove too.
- Do not use this pattern to mask only three or four method calls.