Simple Factory
-
Simple Factory PatternModeling/DesignPattern 2019. 8. 22. 09:16
1. Overview 2. Description 2.1 Motivation Here we simply move the instantiation logic to a separate class and most commonly to a static method of this class Some do not consider a simple factory to be a design pattern, as its simply a method that encapsulates object instantiation. Nothing complex goes on in that method. Typically we want to do this if we have more than one option when instantiat..