added external design pattern documentation links to creational patterns.

This commit is contained in:
tylerlaberge
2016-08-24 21:30:54 -04:00
parent 190e562f08
commit 854966b38b
5 changed files with 16 additions and 6 deletions
+2 -2
View File
@@ -5,8 +5,9 @@ from types import MethodType
class Prototype(object):
"""
Prototype design pattern abstract class.
"""
External Prototype Pattern documentation: U{https://en.wikipedia.org/wiki/Prototype_pattern}
"""
def prototype(self, **attributes):
"""
Copy the prototype this object and optionally update attributes.
@@ -22,4 +23,3 @@ class Prototype(object):
setattr(obj, attribute, attributes[attribute])
return obj