java.lang.Object | ||
↳ | com.microstrategy.web.platform.AbstractConfigurableContainerServices | |
↳ | com.microstrategy.web.platform.DisconnectedContainerServicesImpl |
This class is an intermediary between the ASP.net and Microstrategy Java application. At the start of each ASP page request data and all other necessary data must be copied into the object of this class. After request processing is finished response data must be copied from this object to the response.
[Expand]
Inherited Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() | |||||||||||
![]() |
[Expand]
Inherited Fields | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() |
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
DisconnectedContainerServicesImpl()
The default constructor of this class.
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
void |
addCookieToRequest(String nativeCookieName, String nativeCookieValue)
Adds request cookie to the internal collection
This method is used to add cookies to MicroStrategy Web application.
| ||||||||||
void |
addCookieToResponse(GenericCookie cookie)
This method associates a platform-independent Cookie with a response.
| ||||||||||
void |
addFormAndQueryString(String name, String value)
Adds a value to the request parameters collection.
| ||||||||||
void |
addRequestHeader(String name, String value)
Adds request header to the internal collection
| ||||||||||
void |
addServerVariable(String name, String value)
Adds a server variable with a single value.
| ||||||||||
void |
addServerVariable(String name, String[] values)
Appends a collection of string values of the specified server variable.
| ||||||||||
String | getAppServerInfo() | ||||||||||
Object |
getApplicationAttribute(int index)
Returns application attribute
| ||||||||||
Object |
getApplicationAttribute(String name)
This method returns the value of an Application Attribute.
| ||||||||||
String |
getApplicationAttributeName(int index)
Returns application attribute name
| ||||||||||
int |
getApplicationAttributesCount()
Returns a number of application attributes.
| ||||||||||
String |
getApplicationPath()
This method returns the full application path of the servlet
| ||||||||||
MarkupOutput |
getBinaryMarkup()
Returns markup outut stored at the sendBinaryContent method.
| ||||||||||
int |
getCodePage()
Returns an integer that represents the character formatting codepage.
| ||||||||||
String |
getContentType()
Returns response content type
| ||||||||||
String |
getContextPath()
Returns the context path.
| ||||||||||
ContainerStringCollection |
getCookieStrings()
This method returns the contents of all Cookies as a collection of
sub strings (as name/value pairs).
| ||||||||||
ContainerStringCollection |
getCookieStrings(ContainerServicesNamespace namespace)
This method returns the contents of all Cookies as a collection of
sub strings (as name/value pairs) in the given namespace.
| ||||||||||
boolean |
getCreateNewSessionValue()
Gets a boolean value indicating whether create a new http session
| ||||||||||
int |
getErrorCode()
Returns the error status code for response.
| ||||||||||
String |
getErrorMessage()
Returns the error message for response.
| ||||||||||
ContainerStringCollection |
getFormAndQueryStrings()
This method returns the contents of the Form Data and Query String as a collection of
sub strings (as name/value pairs).
| ||||||||||
AppGlobalContext |
getGlobalContext()
Returns the global context held by this services.
| ||||||||||
String |
getHeaderValue(String headerName)
This method returns the value of the requested header
| ||||||||||
String |
getMethod()
Returns request method, post/get is expected.
| ||||||||||
OutputStream | getOutputStream() | ||||||||||
PostedFile |
getPostedFile(String name)
Provides a way to access individual files that have been uploaded by a client.
| ||||||||||
String |
getQueryString()
This method returns the entire Query String.
| ||||||||||
String |
getRealPath(String relPath)
This method returns the full real path to a server-side file resource.
| ||||||||||
String |
getRemoteAddress()
This method returns the client IP address
| ||||||||||
Object |
getRequestAttribute(String name)
This method returns the value of a Request Attribute.
| ||||||||||
Object |
getRequestAttribute(int index)
Returns requst attribute
| ||||||||||
String |
getRequestAttributeName(int index)
Returns requst attribute name
| ||||||||||
int |
getRequestAttributesCount()
Returns a number of request attributes.
| ||||||||||
String |
getRequestServerName()
This method returns the Web Server Name from the request object
| ||||||||||
URL |
getResource(String relPath)
Returns the
URL associated with the given resource path. | ||||||||||
InputStream |
getResourceAsStream(String relPath)
This method returns the contents of a file resource relative to the web application
as an input stream.
| ||||||||||
Set<String> |
getResourcePaths(String relPath)
Returns a directory path strings of all the paths to resources
within the application whose longest sub-path matches the supplied path.
| ||||||||||
GenericCookie |
getResponseCookie(int index)
Returns a cookie that must be added to the response
| ||||||||||
int |
getResponseCookiesCount()
Returns number of cookeis that must be added to the response
| ||||||||||
String |
getResponseHeaderName(int index)
Returns response header name
| ||||||||||
String |
getResponseHeaderValue(int index)
Returns response header value
| ||||||||||
int |
getResponseHeadersCount()
Returns number of response headers
| ||||||||||
ContainerStringCollection |
getServerVariables()
Returns a collection of server variables.
| ||||||||||
Object |
getSessionAttribute(int i)
Returns session attribute
| ||||||||||
Object |
getSessionAttribute(String name, ContainerServicesNamespace namespace)
This method returns the value of a Session Attribute in the given namespace.
| ||||||||||
Object |
getSessionAttribute(String name)
This method returns the value of a Session Attribute.
| ||||||||||
String |
getSessionAttributeName(int i)
Returns session attribute name
| ||||||||||
int |
getSessionAttributesCount()
Returns a number of session attributes.
| ||||||||||
String |
getSessionID()
Returns HTTP session ID
| ||||||||||
int |
getSessionMaxIdleTime()
Returns the maximum time interval, in seconds, that the container will keep this session open between client accesses.
| ||||||||||
ContainerStringCollection |
getSessionStrings()
This method returns the contents of the Session Variables as a collection of
sub strings (as name/value pairs).
| ||||||||||
ContainerStringCollection |
getSessionStrings(ContainerServicesNamespace namespace)
This method returns the contents of the Session Variables as a collection of
sub strings (as name/value pairs) in the given namespace.
| ||||||||||
int |
getStatusCode()
Returns the HTTP Status code specified for this response.
| ||||||||||
void |
handleMultipartRequest(byte[] request)
This method shall be called if the request type is multipart/form-data
| ||||||||||
boolean | hasOutputStream() | ||||||||||
void |
invalidateHttpSession()
If the security preference is selected, invalidate and create new http session in jsp part
set a flag to show whether a new session need to be created in asp part
| ||||||||||
boolean |
isJavaURLSessionSupported()
Indicates if the instance of this container services supports cookieless environments
| ||||||||||
boolean |
isRequestSecure()
Returns a boolean indicating whether this request was made using a secure channel, such as HTTPS
| ||||||||||
boolean |
isSessionlessRequest()
Does the request has a pre-established session id.
| ||||||||||
void |
sendBinaryContent(MarkupOutput mo)
Outputs binary content of the MarkupOutput
| ||||||||||
boolean |
sendError(int sc)
Sends an error response to the client using the specified status code.
| ||||||||||
boolean |
sendError(int sc, String msg)
Sends an error response to the client using the specified status code.
| ||||||||||
void |
setApplicationAttribute(String name, Object value)
This method sets the value of a Application Attribute.
| ||||||||||
void |
setCodePage(int code)
Sets the code page, an integer representing the character formatting.
| ||||||||||
void |
setContentType(String value)
Stes HTTP response content type
| ||||||||||
void | setControllerName(String name) | ||||||||||
void |
setCreateNewSessionValue(boolean value)
Sets a boolean indicating whether create a new http session
| ||||||||||
void |
setGlobalContext(AppGlobalContext globalContext)
Sets current application global context.
| ||||||||||
void |
setHeaderValue(String headerName, String headerValue)
Sets HTTP response header
| ||||||||||
void |
setJavaURLSessionSupported(boolean value)
Sets if the instance of this container services supports cookieless environments
| ||||||||||
void |
setMethod(String method)
Sets the request method
| ||||||||||
void |
setNativeSessionAttribute(String name, Object value)
This method sets the value of a Session Attribute without using namespace in Session variable.
| ||||||||||
void |
setQueryString(String queryString)
Sets HTTP request query string
| ||||||||||
void |
setRemoteAddress(String remoteAddress)
Set the remote (IP) address for this request
| ||||||||||
void |
setRequestAttribute(String name, Object value)
This method sets the value of a Request Attribute.
| ||||||||||
void |
setRequestSecure(boolean value)
Sets a boolean indicating whether this request was made using a secure channel, such as HTTPS
| ||||||||||
void |
setSessionAttribute(String name, Object value)
This method sets the value of a Session Attribute.
| ||||||||||
void |
setSessionAttribute(String name, Object value, ContainerServicesNamespace namespace)
This method sets the value of a Session Attribute in the given namespace.
| ||||||||||
void |
setSessionID(String sessionID)
Sets the HTTP session ID
| ||||||||||
void |
setStatusCode(int statusCode)
Sets the HTTP Status code specified for this response.
|
Protected Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
String | getControllerName() | ||||||||||
HashList |
getCookies(ContainerServicesNamespace namespace)
Return the a collection of GenericCookie objects from the request cookies.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() | |||||||||||
![]() | |||||||||||
![]() | |||||||||||
![]() | |||||||||||
![]() |
The default constructor of this class.
Adds request cookie to the internal collection This method is used to add cookies to MicroStrategy Web application.
nativeCookieName | The native cookie name used in browser |
---|---|
nativeCookieValue | The native cookie value stored in browser |
This method associates a platform-independent Cookie with a response. When the response is sent back to the client, it will contain this cookie.
cookie | The GenericCookie to be added to the Response.
|
---|
Adds a value to the request parameters collection. There can be several values assosiated with the same name in this collection.
name | parameter name. |
---|---|
value | parameter value. |
Adds request header to the internal collection
name | header name |
---|---|
value | header value |
Adds a server variable with a single value. If the server variable already exists, appends the new value
name | the name of the server variable. |
---|---|
value | the value of the server variable. |
Appends a collection of string values of the specified server variable. If the server variable already exists, appends the new values.
name | the name of the server variable. |
---|---|
values | an array of string values of the server variable. |
Returns application attribute
index | an index in the attribute collection |
---|
This method returns the value of an Application Attribute.
name | the name of an attribute. |
---|
Object
representing the value of a named application attribute.
Returns application attribute name
index | an index in the attribute collection |
---|
Returns a number of application attributes. The Application attributes is a read-writy collection. Attributes can be replaced in it during execution. Therefore entire collection shall be copied in and out of disconnected container services.
This method returns the full application path of the servlet
String
that indicates the full application path
of the servlet. (i.e. http://localhost:8080/MicroStrategy/servlet)
Returns markup outut stored at the sendBinaryContent method. If this method returns not null the content of markup output must be displayed.
Returns an integer that represents the character formatting codepage. The CodePage property specifies how literal (static) strings are encoded in a Web page. A codepage is a character set that can include numbers, punctuation marks, and other glyphs. Codepages are not the same for each language. Some languages have multi-byte characters, while others only need one byte to represent each character.
Returns response content type
Returns the context path. In the out of the box Web application deployment, this is usually "/MicroStrategy". Note that subclasses can override this implementation to return different context paths.
This method returns the contents of all Cookies as a collection of sub strings (as name/value pairs).
ContainerStringCollection
object.
This method returns the contents of all Cookies as a collection of sub strings (as name/value pairs) in the given namespace.
namespace | A ContainerServicesNamespace object representing the namespace requirement.
If null, no namespace is used. |
---|
ContainerStringCollection
object.Gets a boolean value indicating whether create a new http session
Returns the error status code for response.
Returns the error message for response.
This method returns the contents of the Form Data and Query String as a collection of sub strings (as name/value pairs).
ContainerStringCollection
object.
Returns the global context held by this services.
nulll
will be returned.
This method returns the value of the requested header
headerName | A String with the name of the header to search for |
---|
String
with the value of the header requested. If the
header was not found, it shall return a null value.
Returns request method, post/get is expected.
Provides a way to access individual files that have been uploaded by a client.
name | a name of posted file |
---|
This method returns the entire Query String.
String
that contains the contents of the Query String.
This method returns the full real path to a server-side file resource.
relPath | A String that indicates the relative path of the file. |
---|
String
that indicates the full path of the file.
This method returns the client IP address
String
with the value of the client IP address
This method returns the value of a Request Attribute. In Java, there is a clear distinction between Request and Session variables. In ASP, the two are combined as there is not a similar concept.
name | the name of an attribute. |
---|
Object
representing the value of a named attribute.
Returns requst attribute
index | an index in the attribute collection |
---|
Returns requst attribute name
index | an index in the attribute collection |
---|
Returns a number of request attributes. The request attributes is a read-writy collection. Attributes can be replaced in it during execution. Therefore entire collection shall be copied in and out of disconnected container services.
This method returns the Web Server Name from the request object
String
that indicates the Web Server Name. (i.e. if you access the web server with the URL
which reads as http://localhost:8080/MicroStrategy/servlet then this method will return "localhost" as the web server name. If you access
the webserver with the URL which reads as http://machine1:8080/MicroStrategy/servlet then this method will return "machine1" as the web server name.
Returns the URL
associated with the given resource path.
If the resource does not exist, null is returned (i.e. it cannot return
a path to a new java.io.File). Note that many URL
implementations are read-only.
relPath | relative path. |
---|
This method returns the contents of a file resource relative to the web application as an input stream.
This is ONLY required to support the Java environment, and in particular, only those Java environments where the WAR file is not expanded. This should return NULL in an ASP environment.
relPath | A String that indicates the relative path of the file. |
---|
InputStream
that contains the contents of the specified file.
Returns a directory path strings of all the paths to resources within the application whose longest sub-path matches the supplied path.
relPath | sub-path to match |
---|
Returns a cookie that must be added to the response
index | an index in the cookies collection |
---|
Returns number of cookeis that must be added to the response
Returns response header name
index | an index in the collection |
---|
Returns response header value
index | an index in the collection |
---|
Returns number of response headers
Returns a collection of server variables.
Returns session attribute
i | an index in the attribute collection |
---|
This method returns the value of a Session Attribute in the given namespace. In Java, there is a clear distinction between Request and Session variables. In ASP, the two are combined as there is not a similar concept.
name | the name of an attribute. |
---|---|
namespace | A ContainerServicesNamespace object representing the namespace requirement. |
Object
representing the value of a named session attribute.This method returns the value of a Session Attribute. In Java, there is a clear distinction between Request and Session variables. In ASP, the two are combined as there is not a similar concept.
name | the name of an attribute. |
---|
Object
representing the value of a named session attribute.
Returns session attribute name
i | an index in the attribute collection |
---|
Returns a number of session attributes. The session attributes is a read-writy collection. Attributes can be replaced in it during execution. Therefore entire collection shall be copied in and out of disconnected container services.
Returns HTTP session ID
Returns the maximum time interval, in seconds, that the container will keep this session open between client accesses.
This method returns the contents of the Session Variables as a collection of sub strings (as name/value pairs). Only those session variables that return values of type String are considered.
ContainerStringCollection
object.
This method returns the contents of the Session Variables as a collection of sub strings (as name/value pairs) in the given namespace. Only those session variables that return values of type String are considered.
namespace | type of ContainerServicesNamespace The specified namespace. |
---|
ContainerStringCollection
object.Returns the HTTP Status code specified for this response.
This method shall be called if the request type is multipart/form-data
request | a byte array containing entire HTTP request |
---|
IOException |
---|
If the security preference is selected, invalidate and create new http session in jsp part set a flag to show whether a new session need to be created in asp part
Indicates if the instance of this container services supports cookieless environments
Returns a boolean indicating whether this request was made using a secure channel, such as HTTPS
Does the request has a pre-established session id.
Outputs binary content of the MarkupOutput
mo | markup outpu containing binary image |
---|
Sends an error response to the client using the specified status code.
sc | The status errror code. We reuse HTTP status code "OK" (200) to mean no error, so please do not use it for any error status. |
---|
true
to indicate this action succeeded. false
to indicate
error in performing this action.
Sends an error response to the client using the specified status code.
sc | The errror status code. |
---|---|
msg | The error message. |
true
to indicate this action succeeded. false
to indicate
error in performing this action.
This method sets the value of a Application Attribute.
name | A String which identifies the name of the attribute. |
---|---|
value | An Object representing the value of a named attribute.
|
Sets the code page, an integer representing the character formatting. The CodePage property specifies how literal (static) strings are encoded in a Web page. A codepage is a character set that can include numbers, punctuation marks, and other glyphs. Codepages are not the same for each language. Some languages have multi-byte characters, while others only need one byte to represent each character.
code | an integer that represents the character formatting codepage. |
---|
Stes HTTP response content type
value | content type |
---|
Sets a boolean indicating whether create a new http session
Sets current application global context.
globalContext | is an AppGlobalContext object.
|
---|
Sets HTTP response header
headerName | header name |
---|---|
headerValue | header value |
Sets if the instance of this container services supports cookieless environments
value | true if cookieless environment is supported |
---|
Sets the request method
This method sets the value of a Session Attribute without using namespace in Session variable.
name | A String which identifies the name of the attribute. |
---|---|
value | An Object representing the value of a named attribute.
If used in namespaced mode, the native value should containes the namespace encoding, that can be loaded by
load(String) |
Sets HTTP request query string
queryString | request query string |
---|
Set the remote (IP) address for this request
remoteAddress | IP address |
---|
This method sets the value of a Request Attribute. In Java, there is a clear distinction between Request and Session variables. In ASP, the two are combined as there is not a similar concept.
name | A String which identifies the name of the attribute. |
---|---|
value | An Object representing the value of a named attribute.
|
Sets a boolean indicating whether this request was made using a secure channel, such as HTTPS
This method sets the value of a Session Attribute. In Java, there is a clear distinction between Request and Session variables. In ASP, the two are combined as there is not a similar concept.
name | A String which identifies the name of the attribute. |
---|---|
value | An Object representing the value of a named attribute.
|
This method sets the value of a Session Attribute in the given namespace. In Java, there is a clear distinction between Request and Session variables. In ASP, the two are combined as there is not a similar concept.
name | A String which identifies the name of the attribute. |
---|---|
value | An Object representing the value of a named attribute. |
namespace | A ContainerServicesNamespace object representing the namespace requirement.
If null, no namespace is used. |
Sets the HTTP session ID
sessionID | HTTP session ID |
---|
Sets the HTTP Status code specified for this response.
statusCode | the HTTP Status code specified for this response. |
---|
Return the a collection of GenericCookie objects from the request cookies.