Aug 18th, 2006, 11:23 AM
How to get Handle to Current Applln Context from Business Layer
I have 3 layers -
Web Layer - Business Layer - DAO Layer
Currently all 3 layers share same context (which is provided by ContextLoader when the web layer boots up )
But in my service layer (or POJO layer) I want to get access to my current application context to get access to a bean which will be created in prototype mode by the context.
How do I get access to appln context from one of my methods in bussiness layer. (without making assumptions that my layer will always be collocated with web layer)
Just like we have WebApplicationContextUtils, similar to that do we have any class that returns handle to current appln context which is loaded?