Spring MVC Portlet: Accessing beans from portlet context in root context -
it possible access portlet context bean root application context in spring mvc portlet?
if publishcontext
property of dispatcherportlet
is true (default value) can portlet appcontext javax.portlet.portletcontext
as:
applicationcontext otherportletcontext = portletcontext.getattribute(frameworkportlet.portlet_context_prefix + otherportletname);
then use bean of other portlet context as: portletbean = otherportletcontext.getbean(beanname, beanclass);
note can javax.portlet.portletcontext
object implementing portletcontextaware
.
Comments
Post a Comment