com.microstrategy.web.platform.AppGlobalContext |
![]() |
This interface represents the global information of an application. An application could save this at its global level to let each request access them. Currently, this interface is only used by ASP(x) application.
This interface is not thread-safe. The correct usage would be to set this object up in one thread. After it has been set up, all threads should only read information from this object.
This class is not responsible anymore for loading init parameters from "web.xml" or "microstrategy.xml"
Now, this is done by the ApplicationParameters
. To get the value
of an init parameter, get the instance of this class from the com.microstrategy.utils.config.ConfigurationFilesCache
and use the getParameter method, for example:
ApplicationParameters appParams = (ApplicationParameters) ConfigurationFilesCache.getConfiguration("/WEB-INF/microstrategy.xml", ApplicationParameters.class); String value = appParams.getParameter("parameter", "servlet");
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
abstract String |
getApplicationPath()
Returns the application's path.
| ||||||||||
abstract String |
getBasePath()
Returns current application's base path.
| ||||||||||
abstract String |
getInitParameter(String paramName)
This method is deprecated.
The AppGlobalContext is not responsible to load init parameters.Use ContainerServices instead.
| ||||||||||
abstract Enumeration |
getInitParameterNames()
This method is deprecated.
The AppGlobalContext is not responsible to load init parameters.
| ||||||||||
abstract String |
getRequestServerName()
Returns the request server name.
| ||||||||||
abstract String |
getServletName()
This method is deprecated.
The AppGlobalContext should not hold the servlet name
| ||||||||||
abstract void |
loadInitParameters(String relPath, String servletName)
This method is deprecated.
The AppGlobalContext is not responsible to load init parameters. We don't need this method anymore. The implementation of ContainerServices is responsible for loading init parameters.
| ||||||||||
abstract void |
setApplicationPath(String applPath)
Sets the application's base URL used to build link and form URLs.
| ||||||||||
abstract void |
setBasePath(String basePath)
Sets the base path for loading different application resources.
| ||||||||||
abstract void |
setRequestServerName(String serverName)
Sets the request server name
|
Returns the application's path.
IllegalStateException | thrown when the application path has not been set. |
---|
Returns current application's base path.
IllegalStateException | thrown when the application's base path has not been set. |
---|
This method is deprecated.
The AppGlobalContext is not responsible to load init parameters.Use ContainerServices instead.
Returns initialization parameter value
paramName | parameter name |
---|
This method is deprecated.
The AppGlobalContext is not responsible to load init parameters.
Returns enumeration of initialization parameter names
Returns the request server name.
IllegalStateException | thrown when the server name has not been set. |
---|
This method is deprecated.
The AppGlobalContext should not hold the servlet name
Returns the name of the servlet used to initialized this AppGlobalContext.
This method is deprecated.
The AppGlobalContext is not responsible to load init parameters. We don't need this method anymore. The implementation of ContainerServices is responsible for loading init parameters.
Loads servlet's initialization parameters from the web.xml
relPath | relative path to the xml file containig parameters (include the xml name) |
---|---|
servletName | servlet name |
Sets the application's base URL used to build link and form URLs.
applPath | application path |
---|
Sets the base path for loading different application resources.
basePath | a path to a root directory of application resources. All resource pathes are resolved relative to this path. |
---|
Sets the request server name
serverName | The server who serves the request. |
---|