In order to access the data and functionality made available by the PAF, your page should obtain the GearServletResponse and the GearServletRequest. For example:
<% //Obtain request/response GearServletResponse gearServletResponse = (GearServletResponse)request.getAttribute(Attribute.GEARSERVLETRESPONSE); GearServletRequest gearServletRequest = (GearServletRequest)request.getAttribute(Attribute.GEARSERVLETREQUEST); %>
This makes available the following PAF functionality:
Color palette information
Gear instance parameters
Gear user parameters
Current gear instance
Current community
Current URL
Current user’s roles
If your gear page fragments contain references to subsidiary page fragments, then whether or not you need to declare the tag libraries in a particular subsidiary page fragment for a gear depends on how the page fragment is included in its containing page fragment. If the page is included at compile time (using <%@ include ... %>
), then you do not need to supply the includes for that page fragment. If, however, the gear page is included as output (using jsp:include
or dsp:include
), then you would need to initialize the tag libraries within that gear page, since it is essentially a complete JSP page.
For additional information on the PAF Tag Library, refer to Appendix B: PAF Tag Library Reference in this manual.