Class PortalJspBean

java.lang.Object
fr.paris.lutece.portal.web.PortalJspBean

@ApplicationScoped @Named public class PortalJspBean extends Object
This class provides the methods to display the page of the site
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final int
     
    static final int
     
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    getContent(jakarta.servlet.http.HttpServletRequest request)
    Returns the content of a page according to the parameters found in the http request.
    getContent(jakarta.servlet.http.HttpServletRequest request, int nMode)
    Returns the content of a page according to the parameters found in the http request.
    getCredits(jakarta.servlet.http.HttpServletRequest request)
    Returns the code for the popup of the credits
    getError404Page(jakarta.servlet.http.HttpServletRequest request)
    Returns the 404 Error page
    getError500Page(jakarta.servlet.http.HttpServletRequest request, String strCause)
    Returns the 500 Error page
    getError500Page(jakarta.servlet.http.HttpServletRequest request, Throwable exception)
    Returns the 500 Error page
    getLegalInfos(jakarta.servlet.http.HttpServletRequest request)
    Returns the code for the popup of the legal infos
    static String
    getLoginNextUrl(jakarta.servlet.http.HttpServletRequest request)
    Returns the url (asked before login) to redirect after login
    getSiteMessageContent(jakarta.servlet.http.HttpServletRequest request)
    Returns the content of a page according to the parameters found in the http request.
    getSiteMessageContent(jakarta.servlet.http.HttpServletRequest request, int nMode)
    Returns the content of a page according to the parameters found in the http request.
    getStartUpFailurePage(jakarta.servlet.http.HttpServletRequest request)
    Returns the code for the popup of the credits
    static String
    getUploadFilterSiteNextUrl(jakarta.servlet.http.HttpServletRequest request)
    Get the upload filter site next url
    static String
    redirectLogin(jakarta.servlet.http.HttpServletRequest request)
    This method is called by Portal.jsp when it caught an UserNotSignedException.
    static void
    removeUploadFilterSiteNextUrl(jakarta.servlet.http.HttpServletRequest request)
    Remove the upload filter next url from the session
    static String
    sendResource(jakarta.servlet.http.HttpServletRequest request)
    Do send a resource
    static void
    setUploadFilterSiteNextUrl(jakarta.servlet.http.HttpServletRequest request)
    Set the upload filter site next url

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

  • Constructor Details

    • PortalJspBean

      public PortalJspBean()
  • Method Details

    • getContent

      public String getContent(jakarta.servlet.http.HttpServletRequest request) throws UserNotSignedException, SiteMessageException
      Returns the content of a page according to the parameters found in the http request. One distinguishes article, page and xpage and the mode.
      Parameters:
      request - The http request
      Returns:
      the html code for the display of a page of a site
      Throws:
      UserNotSignedException - The UserNotSignedException
      SiteMessageException - occurs when a site message need to be displayed
    • getContent

      public String getContent(jakarta.servlet.http.HttpServletRequest request, int nMode) throws UserNotSignedException, SiteMessageException
      Returns the content of a page according to the parameters found in the http request. One distinguishes article, page and xpage and the mode.
      Parameters:
      request - The http request
      nMode - The mode (normal or administration)
      Returns:
      the html code for the display of a page of a site
      Throws:
      UserNotSignedException - The UserNotSignedException
      SiteMessageException - occurs when a site message need to be displayed
    • getSiteMessageContent

      public String getSiteMessageContent(jakarta.servlet.http.HttpServletRequest request)
      Returns the content of a page according to the parameters found in the http request. One distinguishes article, page and xpage and the mode.
      Parameters:
      request - The http request
      Returns:
      the html code for the display of a page of a site
    • getSiteMessageContent

      public String getSiteMessageContent(jakarta.servlet.http.HttpServletRequest request, int nMode)
      Returns the content of a page according to the parameters found in the http request. One distinguishes article, page and xpage and the mode.
      Parameters:
      request - The http request
      nMode - The mode (normal or administration)
      Returns:
      the html code for the display of a page of a site
    • getStartUpFailurePage

      public String getStartUpFailurePage(jakarta.servlet.http.HttpServletRequest request)
      Returns the code for the popup of the credits
      Parameters:
      request - The HTTP request
      Returns:
      the html code for the popup credits
    • getCredits

      public String getCredits(jakarta.servlet.http.HttpServletRequest request)
      Returns the code for the popup of the credits
      Parameters:
      request - The Http Request
      Returns:
      the html code for the popup credits
    • getLegalInfos

      public String getLegalInfos(jakarta.servlet.http.HttpServletRequest request)
      Returns the code for the popup of the legal infos
      Parameters:
      request - The Http Request
      Returns:
      the html code for the legal infos
    • getError404Page

      public String getError404Page(jakarta.servlet.http.HttpServletRequest request)
      Returns the 404 Error page
      Parameters:
      request - The HTTP request
      Returns:
      The page
    • getError500Page

      public String getError500Page(jakarta.servlet.http.HttpServletRequest request, Throwable exception)
      Returns the 500 Error page
      Parameters:
      request - The HTTP request
      exception - The Exception
      Returns:
      The page
    • getError500Page

      public String getError500Page(jakarta.servlet.http.HttpServletRequest request, String strCause)
      Returns the 500 Error page
      Parameters:
      request - The HTTP request
      strCause - The message
      Returns:
      The page
    • redirectLogin

      public static String redirectLogin(jakarta.servlet.http.HttpServletRequest request)
      This method is called by Portal.jsp when it caught an UserNotSignedException. It gives the login url and stores in the session the url asked
      Parameters:
      request - The HTTP request
      Returns:
      The login page URL
      Since:
      v1.1
    • getLoginNextUrl

      public static String getLoginNextUrl(jakarta.servlet.http.HttpServletRequest request)
      Returns the url (asked before login) to redirect after login
      Parameters:
      request - The Http request
      Returns:
      The url asked before login
      Since:
      v1.1
    • setUploadFilterSiteNextUrl

      public static void setUploadFilterSiteNextUrl(jakarta.servlet.http.HttpServletRequest request)
      Set the upload filter site next url
      Parameters:
      request - the HTTP request
    • getUploadFilterSiteNextUrl

      public static String getUploadFilterSiteNextUrl(jakarta.servlet.http.HttpServletRequest request)
      Get the upload filter site next url
      Parameters:
      request - the HTTP request
      Returns:
      the next url
    • removeUploadFilterSiteNextUrl

      public static void removeUploadFilterSiteNextUrl(jakarta.servlet.http.HttpServletRequest request)
      Remove the upload filter next url from the session
      Parameters:
      request - the HTTP request
    • sendResource

      public static String sendResource(jakarta.servlet.http.HttpServletRequest request) throws SiteMessageException
      Do send a resource
      Parameters:
      request - The request
      Returns:
      The HTML content to display
      Throws:
      SiteMessageException - If the resource or its associated service is not found