Nuxeo Enterprise Platform 5.4

org.nuxeo.ecm.platform.web.common.vh
Class VirtualHostHelper

java.lang.Object
  extended by org.nuxeo.ecm.platform.web.common.vh.VirtualHostHelper

public class VirtualHostHelper
extends Object


Method Summary
static String getBaseURL(ServletRequest request)
           
static String getContextPath(ServletRequest request)
          Returns the context path of the application.
static String getContextPathProperty()
           
static String getServerURL(ServletRequest request)
           
static String getServerURL(ServletRequest request, boolean local)
           
static String getWebAppName(ServletRequest request)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getWebAppName

public static String getWebAppName(ServletRequest request)
Returns:
WebApp name : ie : nuxeo

getServerURL

public static String getServerURL(ServletRequest request)
Returns:
Server URL as : protocol://serverName:port/

getServerURL

public static String getServerURL(ServletRequest request,
                                  boolean local)
Returns:
Server URL as : protocol://serverName:port/

getBaseURL

public static String getBaseURL(ServletRequest request)
Returns:
base URL as protocol://serverName:port/webappName/

getContextPath

public static String getContextPath(ServletRequest request)
Returns the context path of the application. Try to get it from the ServletRequest and then from the org.nuxeo.ecm.contextPath system property. Fallback on default context path /nuxeo.

Parameters:
request -

getContextPathProperty

public static String getContextPathProperty()

Nuxeo Enterprise Platform 5.4

Copyright © 2011 Nuxeo SAS. All Rights Reserved.