Skip to content

Commit 40b5ce5

Browse files
committed
Merge pull request ochococo#28 from garnett/master
Added Mediator pattern and fixed broken link in footer
2 parents b129da1 + 30ecac4 commit 40b5ce5

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

67 files changed

+778
-575
lines changed

Design-Patterns.playground.zip

31.3 KB
Binary file not shown.

Design-Patterns.playground/Documentation/section-13.html

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,6 @@
1313
<section class="section">
1414
<h2 id="-mediator">🚧 Mediator</h2>
1515
<p>The mediator pattern is used to reduce coupling between classes that communicate with each other. Instead of classes communicating directly, and thus requiring knowledge of their implementation, the classes send messages via a mediator object.</p>
16-
<p><em>No example, yet.</em></p>
17-
<h2 id="-memento">💾 Memento</h2>
18-
<p>The memento pattern is used to capture the current state of an object and store it in such a manner that it can be restored at a later time without breaking the rules of encapsulation.</p>
1916
<p><strong>Example:</strong></p>
2017

2118
</section>

Design-Patterns.playground/Documentation/section-17.html

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,8 @@
1111
<body>
1212
<div class="content-wrapper">
1313
<section class="section">
14-
<h2 id="-observer">👓 Observer</h2>
15-
<p>The observer pattern is used to allow an object to publish changes to its state.
16-
Other objects subscribe to be immediately notified of any changes.</p>
14+
<h2 id="-memento">💾 Memento</h2>
15+
<p>The memento pattern is used to capture the current state of an object and store it in such a manner that it can be restored at a later time without breaking the rules of encapsulation.</p>
1716
<p><strong>Example:</strong></p>
1817

1918
</section>

Design-Patterns.playground/Documentation/section-19.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
<body>
1212
<div class="content-wrapper">
1313
<section class="section">
14-
<p><strong>Usage:</strong></p>
14+
<p><strong><em>Usage:</em></strong></p>
1515

1616
</section>
1717
</div>

Design-Patterns.playground/Documentation/section-21.html

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@
1111
<body>
1212
<div class="content-wrapper">
1313
<section class="section">
14-
<h2 id="-state">🐉 State</h2>
15-
<p>The state pattern is used to alter the behaviour of an object as its internal state changes.
16-
The pattern allows the class for an object to apparently change at run-time.</p>
14+
<h2 id="-observer">👓 Observer</h2>
15+
<p>The observer pattern is used to allow an object to publish changes to its state.
16+
Other objects subscribe to be immediately notified of any changes.</p>
1717
<p><strong>Example:</strong></p>
1818

1919
</section>

Design-Patterns.playground/Documentation/section-25.html

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,9 @@
1111
<body>
1212
<div class="content-wrapper">
1313
<section class="section">
14-
<h2 id="-strategy">💡 Strategy</h2>
15-
<p>The strategy pattern is used to create an interchangeable family of algorithms from which the required process is chosen at run-time.</p>
14+
<h2 id="-state">🐉 State</h2>
15+
<p>The state pattern is used to alter the behaviour of an object as its internal state changes.
16+
The pattern allows the class for an object to apparently change at run-time.</p>
1617
<p><strong>Example:</strong></p>
1718

1819
</section>

Design-Patterns.playground/Documentation/section-29.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@
1111
<body>
1212
<div class="content-wrapper">
1313
<section class="section">
14-
<h2 id="-visitor">🏃 Visitor</h2>
15-
<p>The visitor pattern is used to separate a relatively complex set of structured data classes from the functionality that may be performed upon the data that they hold.</p>
14+
<h2 id="-strategy">💡 Strategy</h2>
15+
<p>The strategy pattern is used to create an interchangeable family of algorithms from which the required process is chosen at run-time.</p>
1616
<p><strong>Example:</strong></p>
1717

1818
</section>

Design-Patterns.playground/Documentation/section-33.html

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -11,14 +11,8 @@
1111
<body>
1212
<div class="content-wrapper">
1313
<section class="section">
14-
<h1 id="creational">Creational</h1>
15-
<blockquote>
16-
<p>In software engineering, creational design patterns are design patterns that deal with object creation mechanisms, trying to create objects in a manner suitable to the situation. The basic form of object creation could result in design problems or added complexity to the design. Creational design patterns solve this problem by somehow controlling this object creation.</p>
17-
<p><strong>Source:</strong> <a href="http://en.wikipedia.org/wiki/Creational_pattern">wikipedia.org</a></p>
18-
</blockquote>
19-
<h2 id="-abstract-factory">🌰 Abstract Factory</h2>
20-
<p>The abstract factory pattern is used to provide a client with a set of related or dependant objects.
21-
The &quot;family&quot; of objects created by the factory are determined at run-time.</p>
14+
<h2 id="-visitor">🏃 Visitor</h2>
15+
<p>The visitor pattern is used to separate a relatively complex set of structured data classes from the functionality that may be performed upon the data that they hold.</p>
2216
<p><strong>Example:</strong></p>
2317

2418
</section>

Design-Patterns.playground/Documentation/section-37.html

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,14 @@
1111
<body>
1212
<div class="content-wrapper">
1313
<section class="section">
14-
<h2 id="-builder">👷 Builder</h2>
15-
<p>The builder pattern is used to create complex objects with constituent parts that must be created in the same order or using a specific algorithm.
16-
An external class controls the construction algorithm.</p>
14+
<h1 id="creational">Creational</h1>
15+
<blockquote>
16+
<p>In software engineering, creational design patterns are design patterns that deal with object creation mechanisms, trying to create objects in a manner suitable to the situation. The basic form of object creation could result in design problems or added complexity to the design. Creational design patterns solve this problem by somehow controlling this object creation.</p>
17+
<p><strong>Source:</strong> <a href="http://en.wikipedia.org/wiki/Creational_pattern">wikipedia.org</a></p>
18+
</blockquote>
19+
<h2 id="-abstract-factory">🌰 Abstract Factory</h2>
20+
<p>The abstract factory pattern is used to provide a client with a set of related or dependant objects.
21+
The &quot;family&quot; of objects created by the factory are determined at run-time.</p>
1722
<p><strong>Example:</strong></p>
1823

1924
</section>

Design-Patterns.playground/Documentation/section-41.html

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,10 @@
1111
<body>
1212
<div class="content-wrapper">
1313
<section class="section">
14-
<p>Shorter but oh-so-ugly alternative:</p>
14+
<h2 id="-builder">👷 Builder</h2>
15+
<p>The builder pattern is used to create complex objects with constituent parts that must be created in the same order or using a specific algorithm.
16+
An external class controls the construction algorithm.</p>
17+
<p><strong>Example:</strong></p>
1518

1619
</section>
1720
</div>

0 commit comments

Comments
 (0)