Class BaseURL


  • public class BaseURL
    extends Object
    • Method Detail

      • getServerURL

        public static String getServerURL​(javax.servlet.ServletRequest request,
                                          boolean local)
        Gets the server's URL
        Parameters:
        request - the HTTP request
        local - if the URL must be local
        Returns:
        Server URL as protocol://serverName:port/
      • getWebAppName

        public static String getWebAppName​(javax.servlet.http.HttpServletRequest request)
        Gets the name od the application
        Parameters:
        request - the HTTP request
        Returns:
        WebApp name, i.e.: logicaldoc
      • getBaseURL

        public static String getBaseURL​(javax.servlet.ServletRequest request)
        Gets the base URL
        Parameters:
        request - the HTTP request
        Returns:
        base URL as protocol://serverName:port/webappName/
      • getLocalBaseURL

        public static String getLocalBaseURL​(javax.servlet.http.HttpServletRequest request)