DAO Repertory and Factory

unfininished, but this is a good approach