clean code + add dao factory