lundi 10 septembre 2018

What's the point of using a factory design pattern?

Learning this thing I just can't get it. Why can't we create the object directly, and then assign proper values in setters, or just use a constructor?

I've been looking for answer, but I just can't understand why it's worth to create additional code that we have to look for.

Could anyone explain it simply?

Aucun commentaire:

Enregistrer un commentaire