On 5/12/10 9:32 AM, Wes Wannemacher wrote:
I've seen a few responses, but I think the best way would be to write an interceptor that places the bean into the session. Give it a known name in the session, then you can use OGNL to access it...
That all sounds reasonable, except the part about putting it in the session instead of the request. If there's no compelling reason to store something in the session, I think that it should be avoided. If you're using an interceptor that's going to be doing this injection for each request anyway, you might as well store it in request scope.
If you're storing it in the session, and the bean doesn't change much (and can't get stale), the interceptor might as well at least check to see if it's already present and act as a no-op in that case.
-Dale --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscr...@struts.apache.org For additional commands, e-mail: user-h...@struts.apache.org