Fórum

regd:<Portlet:DefineObjects> tag in jsp

Srikanth Reddy, modificado 13 Anos atrás.

regd:<Portlet:DefineObjects> tag in jsp

Junior Member Postagens: 53 Data de Entrada: 18/06/10 Postagens Recentes
Hi every one
can any one let me know ,what are the Objects that are available in an Jsp ,
if we include the following snippet
<portlet:defineObjects/>
I know very few of them like themeDisplay,renderRequest
Or can any one have any link where we can find out..

Thanks in advance
Srikanth
Arun Kumar S, modificado 13 Anos atrás.

RE: regd:<Portlet:DefineObjects> tag in jsp

Regular Member Postagens: 182 Data de Entrada: 23/06/08 Postagens Recentes
Hi Srikanth,

JSR 168 (Portlet 1.0)

In JSR 168 only three variables are defined:

* RenderRequest renderRequest
* RenderResponse renderResponse
* PortletConfig portletConfig


JSR 268 (Portlet 2.0)

In JSR 286 following variables are defined:

* RenderRequest renderRequest and RenderResponse renderResponse (if the JSP is included from render method)
* ResourceRequest resourceRequest and ResourceResponse resourceResponse (if the JSP is included from serveResource method)
* ActionRequest actionRequest and ActionResponse actionResponse (if the JSP is included from processAction method)
* EventRequest eventRequest and EventResponse eventResponse (if the JSP is included from processEvent method)
* PortletConfig portletConfig
* PortletSession portletSession (returns an existing session or null if no session exists)
* Map<String, Object> portletSessionScope (provides access to the portletSession attributes)
* PortletPreferences portletPreferences (provides access to the portlet preferences)
* Map<String, String[]> portletPreferencesValues (provides access to the portlet preferences as a Map)

HTH,
Arun
Srikanth Reddy, modificado 13 Anos atrás.

RE: regd:<Portlet:DefineObjects> tag in jsp

Junior Member Postagens: 53 Data de Entrada: 18/06/10 Postagens Recentes
Thank you ,i think i should dig into it once.
But your reply helped me a lot ,cause i was in some confusion about it .
If you any link in mind please post it ,so that i can dig into it .

anyway Thanks once again
thumbnail
Tejas Kanani, modificado 12 Anos atrás.

RE: regd:<Portlet:DefineObjects> tag in jsp

Liferay Master Postagens: 654 Data de Entrada: 06/01/09 Postagens Recentes
On top of that if you include <liferay-theme:defineObjects /> it will put a whole bunch of context sensitive objects into our JSP page context. Below is the list for the same.

  • ThemeDisplay themeDisplay
  • Company company
  • Account account
  • User user
  • User realUser
  • Contact contact
  • Layout layout
  • List<Layout> layouts
  • long plid
  • LayoutTypePortlet layoutTypePortlet
  • long scopeGroupId
  • PermissionChecker permissionChecker
  • Locale locale
  • TimeZone timeZone
  • Theme theme
  • ColorScheme colorScheme
  • PortletDisplay portletDisplay
  • long portletGroupId

For more details on that refer below link.
http://www.liferay.com/web/raymond.auge/blog/-/blogs/809893
thumbnail
Ashok Kumar G, modificado 8 Anos atrás.

RE: regd:<Portlet:DefineObjects> tag in jsp

Junior Member Postagens: 27 Data de Entrada: 16/11/11 Postagens Recentes
These are the taglib's you need to import to use the above:

&lt;%@ taglib uri="http://liferay.com/tld/portlet" prefix="liferay-portlet"%&gt;
&lt;%@ taglib uri="http://java.sun.com/portlet_2_0" prefix="portlet"%&gt;
&lt;%@ taglib uri="http://liferay.com/tld/theme" prefix="theme" %&gt;

<portlet:defineobjects />
<theme:defineobjects />