Package com.microstrategy.web.platform
Class AppGlobalContextImpl
- java.lang.Object
-
- com.microstrategy.web.platform.AppGlobalContextImpl
-
- All Implemented Interfaces:
AppGlobalContext
public class AppGlobalContextImpl extends java.lang.Object implements AppGlobalContext
The classAppGlobalContextImpl
provides the default implementation of the interfaceAppGlobalContext
which is applicable only to ASPx application.- Since:
- MicroStrategy Web 7.3.1 or earlier
-
-
Constructor Summary
Constructors Constructor Description AppGlobalContextImpl()
The default constructor of this class.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getApplicationPath()
Returns the application path.java.lang.String
getBasePath()
Returns current application's base path.java.lang.String
getInitParameter(java.lang.String paramName)
Returns initialization parameter valuejava.util.Enumeration
getInitParameterNames()
Returns enumeration of initialization parameter namesjava.lang.String
getRequestServerName()
Returns the request server name.java.lang.String
getServletName()
Returns the name of the servlet used to initialized this AppGlobalContext.void
loadInitParameters(java.lang.String relPath, java.lang.String servletName)
Loads servlet's initialization parameters from the web.xmlvoid
setApplicationPath(java.lang.String applPath)
Sets the application's base URL used to build link and form URLs.void
setBasePath(java.lang.String basePath)
Sets the base path for loading different application resources.void
setRequestServerName(java.lang.String serverName)
Sets the request server name
-
-
-
Method Detail
-
getApplicationPath
public java.lang.String getApplicationPath()
Returns the application path.- Specified by:
getApplicationPath
in interfaceAppGlobalContext
- Returns:
- The current application's path.
- Throws:
java.lang.IllegalStateException
- thrown when the application path has not been set.
-
getInitParameterNames
public java.util.Enumeration getInitParameterNames()
Description copied from interface:AppGlobalContext
Returns enumeration of initialization parameter names- Specified by:
getInitParameterNames
in interfaceAppGlobalContext
- Returns:
- enumeration of initialization parameter names
- See Also:
AppGlobalContext
-
getInitParameter
public java.lang.String getInitParameter(java.lang.String paramName)
Description copied from interface:AppGlobalContext
Returns initialization parameter value- Specified by:
getInitParameter
in interfaceAppGlobalContext
- Parameters:
paramName
- parameter name- Returns:
- parameter value
- See Also:
ContainerServices
-
getServletName
public java.lang.String getServletName()
Description copied from interface:AppGlobalContext
Returns the name of the servlet used to initialized this AppGlobalContext.- Specified by:
getServletName
in interfaceAppGlobalContext
- Since:
- MicroStrategy Web 9.0.0
-
getRequestServerName
public java.lang.String getRequestServerName()
Returns the request server name.- Specified by:
getRequestServerName
in interfaceAppGlobalContext
- Returns:
- The request server name.
- Throws:
java.lang.IllegalStateException
- thrown when the server name has not been set.
-
setApplicationPath
public void setApplicationPath(java.lang.String applPath)
Sets the application's base URL used to build link and form URLs.- Specified by:
setApplicationPath
in interfaceAppGlobalContext
- Parameters:
applPath
- application path
-
setRequestServerName
public void setRequestServerName(java.lang.String serverName)
Sets the request server name- Specified by:
setRequestServerName
in interfaceAppGlobalContext
- Parameters:
serverName
- The server who serves the request.
-
setBasePath
public void setBasePath(java.lang.String basePath)
Sets the base path for loading different application resources.- Specified by:
setBasePath
in interfaceAppGlobalContext
- Parameters:
basePath
- a path to a root directory of application resources. All resource pathes are resolved relative to this path.
-
getBasePath
public java.lang.String getBasePath()
Returns current application's base path.- Specified by:
getBasePath
in interfaceAppGlobalContext
- Returns:
- The curretn application's base path.
- Throws:
java.lang.IllegalStateException
- thrown when the application's base path has not been set.
-
loadInitParameters
public void loadInitParameters(java.lang.String relPath, java.lang.String servletName)
Description copied from interface:AppGlobalContext
Loads servlet's initialization parameters from the web.xml- Specified by:
loadInitParameters
in interfaceAppGlobalContext
- Parameters:
relPath
- relative path to the xml file containig parameters (include the xml name)servletName
- servlet name
-
-