seam portlet

RichFaces Portlet Development

When making an AJAX request from a portlet, it's important to know the differences between the portlet and servlet sessions. For instance, when a user makes an AJAX request inside of the portlet, it happens using a raw HTTP session and the call does not have access to the objects that are in the portal session. For this problem we have implemented a method that will allow us access to the Portlet session attributes. They are scoped using the window id value -- for instance, if the Portlet puts the value 'YourObject' in the Portlet session, it will be stored as 'javax.portlet.p.XYZ?YourObject' where XYZ is the window id.

To access the windowID or scopeID from the UI you may use the following:

#{facesContext.externalContext.sessionMap['org.jboss.portletbridge.WINDOW_ID_RETRIVER'].windowID}
#{facesContext.externalContext.sessionMap['org.jboss.portletbridge.WINDOW_ID_RETRIVER'].scopeId}

你可能感兴趣的:(Ajax,jboss,Richfaces,Access,seam)