Design Patterns Explained
Summary
This course goes beyond merely teaching several design patterns. It also teaches the principles, practices, and approaches that make design patterns "good designs." This empowers students to use advanced design techniques in solving their problems whether design patterns are present or not. After teaching several patterns and the principles underneath them, the course goes further by showing how patterns can work together to create robust, flexible, maintainable designs.Course Objectives
This course teaches participants the correct way to create an object-oriented design by teaching them design patterns. The old style of looking for nouns and verbs to design your classes actually leads to brittle structures. After taking this class, attendees will understand what good design is as well as how to achieve it. After the course participants will:- understand how to add functionality to their designs while minimizing complexity
- understand what design patterns really are, and are not
- know about 12 specific design patterns
- know what code qualities you need to maintain to keep code flexible
- know how to use design patterns to keep code quality high without overdesign
Description
Design patterns are examples of good design, and the principles and practices that lead to it. They are valuable to learn, because knowing them:- provides best-practice wisdom that might not otherwise be thought of
- gives a common set of terminology to enhance team communication
- improves the team-wide quality of design and code
In addition, in our Pattern-Oriented Design classes, we show how:
- design patterns lead to a better understanding of object-oriented design principles
- design patterns work together to give designers a better perspective on their own design problems
- design patterns illustrate a better design approach than merely identifying objects and piecing them together.
We find that (if not addressed in class) these compelling benefits are often not realized until a student has learned a lot of different design patterns. Even then, until they also have a lot of experience using design patterns, they might not look for this type of gain. But by focusing on the principles and strategies underlying design patterns, each attendee at our courses begins improving their abilities as a designer immediately.
Ironically, this approach – that of teaching the principles and strategies of design patterns – also makes them much easier to learn.
Let’s look a little deeper at what we mean.
Better understanding of object-oriented design principles
Too many of us have learned that encapsulation is “data hiding”, or that we find our objects by looking at the nouns in our problem domain and make the verbs our methods. These “strategies” may be good starting points (we actually don’t even agree with that) but they definitely result in an overuse of inheritance and systems that are hard to maintain. The reason design patterns are better designs that your normal, run-of-the-mill designs, is that their developers used a different set of guidelines for object selection. Learning these guidelines will improve your designs whether you actually use design patterns or not.Learning how design patterns can work together
Design patterns as they are often taught, involve one main concept or challenge. In the real world, things typically are much more complicated. In order to use design patterns effectively, it is important to see how patterns can work together to solve real world problems. This is not a problem with design patterns themselves, but rather how they are usually taught. Any course that just discusses design patterns on a one-by-one basis will have minimal impact on your using them in the real world.A new design approach
We typically think of design as a process of identifying our objects and then “putting them together”. Although common, a better approach is available. This better approach involves viewing things at a higher, more conceptual level, without leading to paralysis by analysis. While many experienced architects already do this, it is a very difficult method to teach. Net Objectives has found that this design approach is much easier to understand once design patterns have been explained.Course Level
IntermediateCourse Outline
- Writing Maintainable Code
- Coding First Principles: Loose Coupling, Strong Cohesion, No Redundancy
- Advice from the Gang of Four (the authors of Design Patterns: Elements of Re-usable Object-Oriented Design)
- Basic Object-Oriented Principles: Polymorphism, Encapsulation, Composition
- Discovering the Strategy and Bridge Patterns
- What Are Design Patterns?
- Design Patterns As Coding Best Practices
- Design Patterns As Ways to Contain Variation
- Design Patterns As Forces
- A Comparison of Design Approaches
- "Standard" Entity and Behavior Analysis
- Variation Based Design
- Pattern Based Design
- Commonality/Variability Analysis: How to Design For Variation
- The Strategy Pattern
- The Analysis Matrix and the Abstract Factory
- The Template Method Pattern
- The Bridge Pattern
- The Adapter Pattern
- The Facade
- The Singleton Pattern
- The New Perspective of Object-Oriented Design
- The Family of Proxy Patterns
- The Decorator Pattern
- The Chain of Responsibility Pattern
- The Null Object Pattern
- A Case Study Using Design Patterns
Target Audience
Primary Audience: This course is for experienced developers, testers, designers, architects, technical leads, and those who manage development teams. They should have intermediate to advanced object-oriented experience. If the team uses Agile methods it is suggested they consider our Agile Design Patterns course as an alternative as that is more directed to Agile teams.Secondary Audience: Less experienced developers will find value and should be included if part of an experienced team. In this case we provide pre-course material to help bring them up to speed. If the entire team is inexperienced in Object-Orientation, they will be better served with our Effective Object-Oriented Analysis and Design Course. Project managers have often attended this course to learn the approach of their teams and have found that to be useful.
Room Setup and Equipment Needed
No computer equipment is needed for this course. Classrooms require students at tables (round or long) as well as several white boards or flip-charts. A projector with screen is also needed.Prerequisites
This is a design course, not a coding course. However, knowledge of an object-oriented language (Java, C#, C++, etc.) is important in order to understand the various implementation options we investigate. Net Objectives has online assessments for students who are uncertain about their knowledge level, and online training tools that can help prepare you to get the most out of the course. In particular, the participant must be familiar with inheritance, polymorphism, encapsulation, abstract classes and composition.- Anyone weak in object-orientation should read Part I's "An Introduction to Object-Oriented Software Development" Chapter 1 "The Object-Oriented Paradigm" from Design Patterns Explained: A New Perspective on Object-Oriented Design
- Anyone who doesn't know the UML should read Chapter 2 "The UML—The Unified Modeling Language" from Design Patterns Explained: A New Perspective on Object-Oriented Design
Maximum Number in Class:
24What customers say about this course
"Design patterns no longer seem intimidating"
-- Victor Burton, Developer, XY Point