mercredi 30 septembre 2015

What is difference between factory design pattern and DAO design pattern

Comparing these two patterns I see that they are quite similar: both of them have interface (Product/Dao), factory (ProductFactory/DaoFactory) and concrete implementation (ConcreteProduct,ConcreteDao). Factory creates some concrete implementation object and this object is used by client via interface. So are they similar or I don't understand something? Or is Dao pattern a specific implementation of factory pattern?

Aucun commentaire:

Enregistrer un commentaire