Software Construction: Design Patterns 1
Cards to learn the design patterns
Cards to learn the design patterns
Set of flashcards Details
Flashcards | 14 |
---|---|
Language | Deutsch |
Category | Computer Science |
Level | University |
Created / Updated | 28.12.2019 / 10.11.2024 |
Weblink |
https://card2brain.ch/box/20191228_software_construction_design_patterns_1
|
Embed |
<iframe src="https://card2brain.ch/box/20191228_software_construction_design_patterns_1/embed" width="780" height="150" scrolling="no" frameborder="0"></iframe>
|
The Singleton Pattern (Definition)
The Singleton Pattern ensures a class has only one instance, and provides a global point of access to it.
The Adapter Pattern (Definition)
The Adapter Pattern converts the interface of a class into another interface the clients expect. Adapter lets classes work together that could not otherwise because of incompatible interfaces.
Design Principle (Observer Pattern?)
Strive for loosely coupled designs between objects that interact.
The Iterator Pattern (Definition)
The Iterator Pattern provides a way to access the elements of an aggregate object sequentially without exposing its underlying representation.
Class Diagram of Iterator Pattern
Aggregate ist z.B. ein Menu Interface während ConcreteAggregate eine spezifische Implementation dessen ist. Die spezifische Implementation benötigt weiter eine spezifische Implementation des Iterator Interfaces bzw. einen ConcreteIterator. Der Client, z.B. der Kellner im Beispiel, muss nur die beiden Interfaces nutzen (!=implementieren!).