mnapoli/PHP-DI — pull request #89 by jflitton (2013-07-24 20:21:13+00:00)
Title: Adding functionality to inject dependencies into an existing object

Hi!

I've added functionality for injecting into an existing object. This is handy under certain testing circumstances and when you lack complete control over the instantiation of an object for some reason.

I added this functionality so that I could easily use PHP-DI in ZF2. While I haven't figured out a graceful way to use PHP-DI to instantiate controllers in ZF2's version of the dispatcher, I can at least get the resulting controller from Dispatch() and inject it after the fact.

Think this is worth integrating into your code base?

Thanks,

Jeff