|
From: Alef A. \(JTeam\) <al...@jt...> - 2003-09-25 07:29:55
|
Thanks! There is something in the JavaDoc, but it doesn't explicitly state the applicationcontext isn't set yet... Maybe we should have state-like diagrams or a on page description of the lifecycle of a bean bean in the container when using the different callback interfaces available... Alef -----Oorspronkelijk bericht----- Van: spr...@li... [mailto:spr...@li...] Namens Rod Johnson Verzonden: Wednesday, September 24, 2003 9:22 PM Aan: al...@jt...; spr...@li... Onderwerp: Re: [Springframework-developer] setApplicationContext() not called on Singletons??? > Ok, I admit, I didn't think hard enough ;-) > > afterPropertiesSet() is called after all properties are set. > setApplicationContext() is called when getting a bean from the > Context. > > So I'm basically not allowed to do anything related to the > ApplicationContext in my afterPropertiesSet() method??? Yes. Sorry I didn't remember and point this out earlier. Configuring the ApplicationContext layer is a later stage of configuration than configuring the BeanFactory layer. We should document this more prominently though. (I seem to remember putting something in Javadocs). So if you do everything that depends on the AppContext is setApplicationContext() you should be OK. ------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf _______________________________________________ Springframework-developer mailing list Spr...@li... https://lists.sourceforge.net/lists/listinfo/springframework-developer |