News

Benefits of Java design patterns. ... The Factory Design pattern is used when we have a superclass with multiple subclasses and, based on input, we need to return one of the subclasses.