What are the differences between Abstract Factory and Factory design patterns?

后端 未结 17 1144
醉话见心
醉话见心 2020-11-22 01:57

I know there are many posts out there about the differences between these two patterns, but there are a few things that I cannot find.

From what I have been reading,

17条回答
  •  终归单人心
    2020-11-22 02:40

    Allow me to put it precisely. Most of the answers have already explained, provided diagrams and examples as well.

    So my answer would just be a one-liner. My own words: “An abstract factory pattern adds on the abstract layer over multiple factory method implementations. It means an abstract factory contains or composite one or more than one factory method pattern”

提交回复
热议问题