You have now explored five patterns in depth and looked at capsule summaries of quite a few more.
This module discusses some general issues that arise in using patterns to develop software.
In this module, you will learn:
- How to choose the right pattern for the job
- How to modify documented patterns to fit your problem
- How to combine design patterns
- The pitfalls and limitations of patterns
Patterns, specifically in the realm of software design, are powerful tools that encapsulate solutions to recurring problems within a particular context. However, the application of patterns isn't without its issues. These issues can manifest themselves in various ways and at different points in the software development lifecycle. Here are some general issues that may arise:
- Misuse and Overuse of Patterns: One of the most common issues is the misuse or overuse of patterns. This usually occurs when developers treat patterns as the ultimate solution to every problem, leading to their overuse. This could result in an overly complex design, which is hard to understand, maintain, and modify.
- Context Ignorance: Each pattern is designed for a specific context. Applying a pattern outside its appropriate context can lead to a counterproductive design.
- Impediment to Creativity: Strict adherence to design patterns may stifle creativity and inhibit the development of novel, more efficient solutions to a problem.
- Inefficiency due to Pattern Overhead: Every design pattern comes with its own overhead. While the overhead might be negligible in larger systems, in smaller systems it could lead to inefficiency.
- Lack of Flexibility: A pattern-oriented approach might sometimes result in rigid, tightly-coupled systems that are resistant to change, thereby limiting flexibility.
Software design is the process by which an agent creates a specification of a software artifact, intended to accomplish goals, using a set of primitive components and subject to constraints. Software design may refer to either
- "all the activities involved in conceptualizing, framing, implementing, commissioning, and ultimately modifying complex systems" or
- "the activity following requirements specification and before programming, as in the style of a software engineering process."
Software design usually involves problem solving and planning a software solution.
This includes both low-level component and algorithm design as well as high-level, architecture design.