Jetspeed2 (JSR 286) support for 2 Portlet instances on the same Portal
That's a pure newbie question.. actually not even newbie.. still investigating! I 开发者_如何学Pythonwant to know if 2 instances of the same Portlet would have separate scopes? What is this scope called, maybe Application Scope? Would that hold if they are deployed on the same WAR?
The JavaDoc of the PortletSession class says:
"All objects stored in the session using the APPLICATION_SCOPE must be available to all the portlets, servlets and JSPs that belongs to the same portlet application and that handles a request identified as being a part of the same session. Objects stored in the session using the PORTLET_SCOPE must be available to the portlet during requests for the same portlet window that the objects where stored from."
There you go. PORTLET_SCOPE is the scope for each instance of a portlet.
P.S: read the JavaDoc of the APIa you want to use before asking these questions.
精彩评论