Given:
Which design pattern moves the getPerson, createPerson, deletePerson, and updatePerson methods to a new class?
A.
Singleton
B.
DAO
C.
Factory
D.
Composition
Explanation:
We move the most abstract highest level methods into a separate class.
Note:Data Access Object
Abstracts and encapsulates all access to a data source
Manages the connection to the data source to obtain and store data
Makes the code independent of the data sources and data vendors (e.g. plain-text, xml, LDAP, MySQL, Oracle, DB2)