Skip to main content
7 events
when toggle format what by license comment
Mar 18, 2013 at 3:06 vote accept educampver
Mar 18, 2013 at 0:04 comment added Rocklan @jhewlett - that's fantastic, I've been looking for a good simple stubbing technique for unit testing that doesn't over complicate my solution - and I think this is it :)
Mar 17, 2013 at 11:09 comment added Ian I use property setter injection specifically to populate some configuration classes which include a large number of values. I don't use it anywhere else. I'm always a bit dubious about making a case for optional parameters because there's a good chance it's an infraction of the single responsibility rule. Of course rules are meant to be broken, so ...
Mar 17, 2013 at 6:49 comment added jhewlett You probably wouldn't want to use constructor injection for optional dependencies. I can't think of any other reasons not to use it.
Mar 17, 2013 at 6:41 history edited jhewlett CC BY-SA 3.0
added 2 new points
Mar 17, 2013 at 6:35 comment added educampver thanks, that's quite close to what I understand, but still, is there any scenario where you can't use constructor injection?
Mar 17, 2013 at 6:22 history answered jhewlett CC BY-SA 3.0