tag:blogger.com,1999:blog-142015575677144593.post2201938892977442628..comments2023-06-05T03:59:31.858-04:00Comments on Ramblings of an Internet MoFo: Reminder of Wirebox Dependency Injection LifecycleNicholas Tunneyhttp://www.blogger.com/profile/04500115069703249854noreply@blogger.comBlogger2125tag:blogger.com,1999:blog-142015575677144593.post-17076078984797504572015-07-17T08:44:31.290-04:002015-07-17T08:44:31.290-04:00Yes Dom, I believe that constructor injection is t...Yes Dom, I believe that constructor injection is the only way to avoid having to use onDIComplete() or the onDIComplete method annotation. For both mixin injection and setter methods Wirebox waits to perform DI until after init() is called to prevent circular references.Nicholas Tunneyhttps://www.blogger.com/profile/04500115069703249854noreply@blogger.comtag:blogger.com,1999:blog-142015575677144593.post-4460854558659503102015-07-16T20:29:07.127-04:002015-07-16T20:29:07.127-04:00I prefer the more portable constructor injection s...I prefer the more portable constructor injection syntax for this reason (as well as it makes the object truly agnostic of the DI engine):<br /><br />/**<br /> * @myDao.inject myDao<br /> *<br /> */<br />public any function init( required any myDao ) {<br /> // stuff...<br />}Domhttps://www.blogger.com/profile/01927539923118254718noreply@blogger.com