Not the most elegant solution, but you can pull the ApplicationContext
from the ServletContext:

ServletContext sc = ServletActionContext.getServletContext();
(ApplicationContext)sc.getAttribute("org.springframework.web.context.WebApplicationContext.ROOT");

Josh

On 5/23/07, Célio Cidral Junior <[EMAIL PROTECTED]> wrote:
Hi,

I want to implement an OpenInView pattern interceptor involving
Hibernate, but there's a problem. My SessionFactory is both created
and managed by Spring, and my interceptor should have access to that
SessionFactory, however I don't know how to do that. I have already
searched a lot the web and the docs but couldn't find an answer. Does
anybody know if that's possible (and how)?.

Regards,

Célio.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to