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

Plumbing the construction of your object graph manually does not have a particularly high cost/benefit - most of your services are singletons that depend on each other, and it's already clear enough which ones depend on which others without repeating yourself. A very basic "here's a bag of classes that depend on each other, wire them all together and then let me pull out the instances by type" is often worthwhile for avoiding all that boilerplate, even if it does break the rules of the language a little. Something like Picocontainer or even Guice is pretty good IME.


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

Search: