fr.paris.lutece.portal.web.portlet
Class PortletJspBean

java.lang.Object
  extended by fr.paris.lutece.portal.web.admin.AdminFeaturesPageJspBean
      extended by fr.paris.lutece.portal.web.portlet.PortletJspBean
Direct Known Subclasses:
AliasPortletJspBean

public abstract class PortletJspBean
extends AdminFeaturesPageJspBean

This class represents user interface Portlet. It is the base class of all user interface portlets. It is abstract and the implementation of the interface PortletJspBeanInterface is compulsary.


Field Summary
protected static java.lang.String PARAMETER_PAGE_ID
           
protected static java.lang.String PARAMETER_PORTLET_ID
           
protected static java.lang.String PARAMETER_PORTLET_TYPE_ID
           
static java.lang.String RIGHT_MANAGE_ADMIN_SITE
           
 
Constructor Summary
PortletJspBean()
           
 
Method Summary
abstract  java.lang.String doCreate(javax.servlet.http.HttpServletRequest request)
          Processes portlet's creation
abstract  java.lang.String doModify(javax.servlet.http.HttpServletRequest request)
          Processes portlet's modification
abstract  java.lang.String getCreate(javax.servlet.http.HttpServletRequest request)
          Displays the portlet's creation form
protected  fr.paris.lutece.util.html.HtmlTemplate getCreateTemplate(java.lang.String strPageId, java.lang.String strPortletTypeId)
          Fills templates with common values shared by portlet creation form
protected  fr.paris.lutece.util.html.HtmlTemplate getCreateTemplate(java.lang.String strPageId, java.lang.String strPortletTypeId, java.util.Map<java.lang.String,java.lang.Object> model)
          Fills templates with common values shared by portlet creation form
abstract  java.lang.String getModify(javax.servlet.http.HttpServletRequest request)
          Displays the portlet's modification form
protected  fr.paris.lutece.util.html.HtmlTemplate getModifyTemplate(Portlet portlet)
          Fills update template with portlet values
protected  fr.paris.lutece.util.html.HtmlTemplate getModifyTemplate(Portlet portlet, java.util.Map<java.lang.String,java.lang.Object> model)
          Fills update template with portlet values
protected  java.lang.String getPageUrl(int nIdPage)
          Gets the page URL
protected  void putCheckBox(java.util.Map<java.lang.String,java.lang.Object> model, java.lang.String strMarkerChecked, boolean bChecked)
           
protected  java.lang.String setPortletCommonData(javax.servlet.http.HttpServletRequest request, Portlet portlet)
          Recovers the common attributes of the portlet
 
Methods inherited from class fr.paris.lutece.portal.web.admin.AdminFeaturesPageJspBean
getAdminPage, getFeatureIcon, getHomeUrl, getLocale, getPageTitle, getUser, init, populate, setFeatureIcon, setPageTitleProperty
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

RIGHT_MANAGE_ADMIN_SITE

public static final java.lang.String RIGHT_MANAGE_ADMIN_SITE
See Also:
Constant Field Values

PARAMETER_PAGE_ID

protected static final java.lang.String PARAMETER_PAGE_ID
See Also:
Constant Field Values

PARAMETER_PORTLET_ID

protected static final java.lang.String PARAMETER_PORTLET_ID
See Also:
Constant Field Values

PARAMETER_PORTLET_TYPE_ID

protected static final java.lang.String PARAMETER_PORTLET_TYPE_ID
See Also:
Constant Field Values
Constructor Detail

PortletJspBean

public PortletJspBean()
Method Detail

getCreate

public abstract java.lang.String getCreate(javax.servlet.http.HttpServletRequest request)
Displays the portlet's creation form

Parameters:
request - The http request
Returns:
The html code for displaying the creation form

doCreate

public abstract java.lang.String doCreate(javax.servlet.http.HttpServletRequest request)
Processes portlet's creation

Parameters:
request - The http request
Returns:
The Management jsp url

getModify

public abstract java.lang.String getModify(javax.servlet.http.HttpServletRequest request)
Displays the portlet's modification form

Parameters:
request - The http request
Returns:
The html code for displaying the modification form

doModify

public abstract java.lang.String doModify(javax.servlet.http.HttpServletRequest request)
Processes portlet's modification

Parameters:
request - The http request
Returns:
The Management jsp url

setPortletCommonData

protected java.lang.String setPortletCommonData(javax.servlet.http.HttpServletRequest request,
                                                Portlet portlet)
Recovers the common attributes of the portlet

Parameters:
request - the http request
portlet - The instance of the portlet
Returns:
An error Key if error, otherwise null.

getCreateTemplate

protected fr.paris.lutece.util.html.HtmlTemplate getCreateTemplate(java.lang.String strPageId,
                                                                   java.lang.String strPortletTypeId)
Fills templates with common values shared by portlet creation form

Parameters:
strPageId - the page identifier
strPortletTypeId - the Portlet type identifier
Returns:
the template filled

getCreateTemplate

protected fr.paris.lutece.util.html.HtmlTemplate getCreateTemplate(java.lang.String strPageId,
                                                                   java.lang.String strPortletTypeId,
                                                                   java.util.Map<java.lang.String,java.lang.Object> model)
Fills templates with common values shared by portlet creation form

Parameters:
strPageId - the page identifier
strPortletTypeId - the Portlet type identifier
model - Specific data stored in a hashtable
Returns:
the template filled

getModifyTemplate

protected fr.paris.lutece.util.html.HtmlTemplate getModifyTemplate(Portlet portlet)
Fills update template with portlet values

Parameters:
portlet - the object to update
Returns:
the update template filled

getModifyTemplate

protected fr.paris.lutece.util.html.HtmlTemplate getModifyTemplate(Portlet portlet,
                                                                   java.util.Map<java.lang.String,java.lang.Object> model)
Fills update template with portlet values

Parameters:
portlet - the object to update
model - The Data model
Returns:
the update template filled

putCheckBox

protected void putCheckBox(java.util.Map<java.lang.String,java.lang.Object> model,
                           java.lang.String strMarkerChecked,
                           boolean bChecked)

getPageUrl

protected java.lang.String getPageUrl(int nIdPage)
Gets the page URL

Parameters:
nIdPage - Page ID
Returns:
The page URL


Copyright © 2012 Mairie de Paris. All Rights Reserved.