Design Patterns
Design patterns are reusable solutions to recurring problems in software architecture and object-oriented design. They provide shared vocabulary and proven structural templates — like factories, observers, and strategies — that make code more flexible and easier to communicate about.
itSoftware engineering | OpenSkills.info
Intro
Design Patterns
Design patterns give names to recurring software design problems and proven ways to organize a solution. A pattern is not a library or a code template. You adapt its roles and relationships to your context.
That distinction matters. An algorithm tells you which steps to execute. A design pattern describes how responsibilities can collaborate. Two implementations of the same pattern may look different while preserving the same intent.
Why patterns exist
Software changes. New output formats appear. External systems expose incompatible interfaces. Business rules gain variants. A design that binds every decision into one class makes each change spread.
A pattern identifies a recurring pressure and a structure that can contain it. The shared name also gives your team a compact design vocabulary. Saying “Strategy” can focus a discussion on interchangeable behavior. It does not remove the need to explain the actual business rule.
The classic catalog by Erich Gamma, Richard Helm, Ralph Johnson, and John Vlissides presents 23 object-oriented patterns. The catalog groups them by intent:
- Creational patterns vary how objects are created.
- Structural patterns compose classes and objects into larger structures.
- Behavioral patterns distribute algorithms and responsibilities among objects.
These categories are a map, not a selection procedure. Start with the problem and the likely direction of change. Choose a pattern only when its consequences fit both.
Continue the course
This section is part of the paid course.
See pricing to subscribe, or log in if you already have access.
Where this skill leads
Relevant careers
See how this topic contributes to broader role-level skill maps.
Sources
- https://www.pearson.com/en-us/subject-catalog/p/design-patterns-elements-of-reusable-object-oriented-software/P200000009480/9780321700698
Supports
- Canonical authorship, publication, and object-oriented scope of Design Patterns
- Catalog size of 23 patterns and its creational, structural, and behavioral organization
- Patterns as named and evaluated solutions to recurring object-oriented design problems
- https://refactoring.guru/design-patterns/what-is-pattern
Supports
- A pattern as an adaptable design concept rather than finished code
- Difference between a design pattern and an algorithm
- Intent, motivation, structure, applicability, implementation, and relationship fields in pattern descriptions
- https://refactoring.guru/design-patterns/catalog
Supports
- Membership and intent of the creational, structural, and behavioral groups
- Names of the classic patterns listed in the cheatsheet
- https://refactoring.guru/design-patterns/strategy
Supports
- Strategy intent, interchangeable algorithms, context delegation, applicability, and trade-offs
- https://learn.microsoft.com/en-us/dotnet/standard/events/observer-design-pattern
Supports
- Provider, observer, subscription, and push-notification roles
- Notification ordering, unsubscription, state payload, and alternative mechanism considerations
- https://refactoring.guru/design-patterns/adapter
Supports
- Adapter intent, interface translation, participants, object composition, and applicability
- https://refactoring.guru/design-patterns/decorator
Supports
- Decorator intent, interface-preserving wrappers, behavior composition, order, and trade-offs
- https://refactoring.guru/design-patterns/factory-method
Supports
- Factory Method intent, deferred concrete product selection, applicability, and added complexity
- https://refactoring.guru/design-patterns/relations
Supports
- Intent-based distinctions and common relationships among classic patterns
- https://learn.microsoft.com/en-us/dotnet/core/extensions/dependency-injection/basics
Supports
- Dependency injection as removal of hard-coded dependencies
- Service contracts, registration, provider resolution, implementations, and service lifetimes
- https://learn.microsoft.com/en-us/azure/architecture/patterns/
Supports
- Distributed-system pattern scope and technology-agnostic use
- Pattern-specific problems, considerations, examples, and trade-offs
- Reliability, security, cost, operations, and performance design forces
