Facade Pattern: A single class that represents the entire system. It is needed when one simple action needs many other action behind the scenes.
Example: A withdrawal from bank includes following actions
- Check if account is valid
- Check if Pin is valid
- Check if Amount is sufficient
- Make changes accordingly
Continue reading “Facade Design Pattern”
Design Pattern: As the name suggests, design patterns are set of patterns used in software design, which provide solution to a commonly occurring problem. Design patterns are formalized best practices that the programmer can use to solve common problems when designing an application or system.
In other words, Design patterns are structured approach to computer programming and its architecture.
Patterns are about reusable designs and interactions of objects.
Gang of Four: The 23 Gang of Four (GoF) patterns are generally considered the foundation for all other patterns. They are categorized in three groups: Creational, Structural, and Behavioral (for a complete list see below). Continue reading “Design Patterns and Gang of Four”