Improve Prototype description

This commit is contained in:
Ilkka Seppälä 2020-07-24 16:45:28 +03:00
parent 689486267d
commit 205b87cd93

View File

@ -10,10 +10,13 @@ tags:
--- ---
## Intent ## Intent
Specify the kinds of objects to create using a prototypical Specify the kinds of objects to create using a prototypical instance, and create new objects by copying this prototype.
instance, and create new objects by copying this prototype.
## Explanation ## Explanation
First it should be noted that Prototype pattern is not used to gain performance benefits. It's only used for creating
new objects from prototype instance.
Real world example Real world example
> Remember Dolly? The sheep that was cloned! Lets not get into the details but the key point here is that it is all about cloning. > Remember Dolly? The sheep that was cloned! Lets not get into the details but the key point here is that it is all about cloning.