Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I like dependency injection for wiring together configured singletons (such as factories). What I don't like is a trivial constructor and then injection via setters. Constructors should produce objects ready for use, and Spring tolerates doing it that way (though it seems to prefer setters).


Consider applying for YC's Winter 2027 batch! Applications are open till November 2.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: