public interface

WebIServerSession

implements WebSessionInfo RegionalOptions ServerInfo
com.microstrategy.web.objects.WebIServerSession
Known Indirect Subclasses

Class Overview

The WebIServerSession represents a MicroStrategy Intelligence Server session. It allows the user to set the server name, port and project, among others, to start an Intelligence Server session.

Summary

[Expand]
Inherited Constants
From interface com.microstrategy.utils.serialization.EnumWebPersistableState
[Expand]
Inherited Fields
From interface com.microstrategy.utils.cache.CacheHint
From interface com.microstrategy.web.objects.WebSessionInfo
Public Methods
abstract boolean checkUserPrivilege(int privilegeType)
Checks if the user has the particular privilege type at Intelligence Server
abstract void clearToken()
Clears the token.
abstract WebIServerSession createCopy()
Creates a new WebIServerSession instance and copies into it data necessary to connect to the I-Server.
abstract String createUsherAccount(String email)
abstract void deleteTrustToken(String tokenString, String severName)
Delete Trust Relationship between Web Server and Intelligence Server.
abstract String generateNewTrustToken(String identifier)
Create Trust Relationship between Web Server and Intelligence Server.
abstract String getAccessToken()
This access token (Usher, OAuth2) will be passed to the Intelligence Server for authentication.
abstract int getApplicationType()
Returns the application type to be set on the session, from EnumDSSXMLApplicationType.
abstract int getAuthMode()
Returns the current setting of the authMode property, which determines the type of credentials used upon creating a session to the Intelligence Server.
abstract String getClientID()
Returns the current value of the client ID identifier, which is used upon session creation to identify the client machine.
abstract String getClientVersion()
Returns the current value of the client version, which is used upon session creation to identify the client's version.
abstract String getExtraParams()
abstract String getExtraProperty(String name)
Get the extra property.
abstract GSSCredential getGSSCredential()
Get GSS Delegation Credential for Kerberos Authentication mode
abstract String getKey()
Returns the unique key which identifies this session within its list.
abstract String getLDAPDistinguishedName()
Get LDAP Distinguished Name for Single Sign on authentication mode
abstract long getLastAccessTime()
Returns the last access time of the session.
abstract String getMessageID()
abstract String getOrgID()
Gets the Usher organization/network ID associated with this session.
abstract SimpleList getOutOfComplianceLicenses(int[] levels)
Returns the list of out of compliance licenses (of required compliance levels) for the current user session.
abstract String getPartialURL()
Returns the partial url set by setPartialURL(String)
abstract String getProjectID()
Returns the project ID corresponding to the projectName that was set.
abstract String getProjectName()
Returns the project name which will be logged into.
abstract int getRegularWorkingSetSize()
Returns the regular working set size which is currently set on the object.
abstract String getResultCode()
abstract int getSearchWorkingSetSize()
Returns the search working set size which is currently set on the object.
abstract String getServerName()
Returns the Intelligence Server name to be contacted when creating a session.
abstract int getServerPort()
Returns the Intelligence Server port which will be connected to when sending a request.
abstract String getServerVersion()
Returns the version of the Intelligence Server specified by the serverName and port properties.
abstract int getSessionFlags()

Returns the flag settings which will be used upon calling createSession or closeSession.

abstract String getSessionKey()
Get session key for mobile encryption
abstract String getTrustToken()
Get Trust Token for Single Sign on authentication mode
abstract Preferences getUserPreferences()
abstract UsherSessionHelper getUsherSessionHelper()
abstract String getWebVersion()
Returns the version of the Web API which is being used.
abstract boolean isMDUser()
Returns a boolean to indicate whether the user that this session corresponds to is an actual user persisted in the metadata.
abstract void populate(WebIServerSession otherSession)
This method can be used to populate the current session with the information from the given session.
abstract void resolveLocalesOnly(WebUserEntity oUserEntity)
Connects to the Intelligence Server to resolve the locales without creating a session.
abstract void resolveLocalesOnly()
Connects to the Intelligence Server to resolve the locales without creating a session.
abstract void setAccessToken(String accessToken)
Sets the two-step verification code
abstract void setApplicationType(int applicationType)
Sets the application type to use when creating the session, from EnumDSSXMLApplicationType.}
abstract void setAuthMode(int authMode)
Sets the current setting of the authMode property, which determines the type of credentials used upon creating a session to the Intelligence Server.
abstract void setClientID(String clientID)
Sets the value of the client identifier, which tells the Intelligence Server upon login the identifier of the client machine.
abstract void setClientVersion(String clientVersion)
Sets the value of the client version, which tells the Intelligence Server upon login the version of the client.
abstract void setConfSessionID(String confSessionID)
Set the configuration session ID.
abstract void setExtraParams(String value)
abstract void setExtraProperty(String name, String value)
Set extra property on this session object.
abstract void setGSSCredential(GSSCredential credential)
Set GSS Delegation Credential for Kerberos Authentication mode
abstract void setLDAPDistinguishedName(String LDAPDN)
Set LDAP Distinguished Name for Single Sign on authentication mode
abstract void setLastMsgID(String lastMsgID)
set the last message ID
abstract void setOrgID(String orgID)
Sets the Usher organization/network ID.
abstract void setPartialURL(String url)
Defines partial url that will used to replace the {&WEBSERVER} macro whereever it is used The macro is used , for instance, in Report Services document.
abstract void setProjectID(String dssID)
Sets the project DSS ID which will be logged into.
abstract void setProjectName(String projectName)
Sets the project name which will be logged into.
abstract void setRegularWorkingSetSize(int newRegularWorkingSetSize)
Sets the regular working set size.
abstract void setSearchWorkingSetSize(int newSearchWorkingSetSize)
Sets the search working set size.
abstract void setServerName(String serverName)
Sets the Intelligence Server name to be contacted when creating a session.
abstract void setServerPort(int portNumber)
Sets the Intelligence Server port which will be connected to when sending a request.
abstract void setSessionFlags(int newSessionFlags)
This value should be the bitwise or(|) of values from EnumDSSXMLSessionFlags.
abstract void setSessionKey(String sessionKey)
Set session key for mobile encryption
abstract void setToken(Object token)
Sets the token.
abstract void setTrustToken(String token)
Set Trust Token for Single Sign on authentication mode
abstract void setTwoStepVerificationCode(String twoStepVerificationCode)
Sets the two-step verification code
abstract void updateSessionParameters()
Normally, the following parameters are established during session creation.
[Expand]
Inherited Methods
From interface com.microstrategy.utils.cache.CacheHint
From interface com.microstrategy.utils.serialization.Persistable
From interface com.microstrategy.web.objects.WebSessionInfo
From interface com.microstrategy.web.objects.localization.RegionalOptions
From interface com.microstrategy.web.objects.localization.RegionalValues
From interface com.microstrategy.webapi.ServerInfo

Public Methods

public abstract boolean checkUserPrivilege (int privilegeType)

Checks if the user has the particular privilege type at Intelligence Server

Parameters
privilegeType integer value specifying the type of privilege that is to be checked This is a value from the enumeration EnumDSSXMLPrivilegeTypes
Returns
  • boolean value indicating if the specific privilege is available

public abstract void clearToken ()

Clears the token.

public abstract WebIServerSession createCopy ()

Creates a new WebIServerSession instance and copies into it data necessary to connect to the I-Server.

The following fields are copied to the new object:

  • serverName;
  • portNumber;
  • projectName;
  • authMode;
  • login;
  • password;
  • regularWorkingSetSize;
  • searchWorkingSetSize;
  • sessionFlags;

Returns
  • new session instance

public abstract String createUsherAccount (String email)

public abstract void deleteTrustToken (String tokenString, String severName)

Delete Trust Relationship between Web Server and Intelligence Server.

Parameters
tokenString token for the trust relationship to be deleted
severName the Web Server name for the Trust relationship

public abstract String generateNewTrustToken (String identifier)

Create Trust Relationship between Web Server and Intelligence Server.

Parameters
identifier the web application name passed to Intelligence Server
Returns
  • Trust token for the create trust relationship

public abstract String getAccessToken ()

This access token (Usher, OAuth2) will be passed to the Intelligence Server for authentication. Note that the access token takes precedence, and is mutually exclusive with getTrustToken(), i.e. if access token is available, we ignore the trust token.

Returns
  • access token

public abstract int getApplicationType ()

Returns the application type to be set on the session, from EnumDSSXMLApplicationType.

Returns

public abstract int getAuthMode ()

Returns the current setting of the authMode property, which determines the type of credentials used upon creating a session to the Intelligence Server.

Returns
See Also

public abstract String getClientID ()

Returns the current value of the client ID identifier, which is used upon session creation to identify the client machine.

Returns
  • The client ID value which will be used.

public abstract String getClientVersion ()

Returns the current value of the client version, which is used upon session creation to identify the client's version.

Returns
  • The client version value which will be used.

public abstract String getExtraParams ()

public abstract String getExtraProperty (String name)

Get the extra property.

Parameters
name property name
Returns
  • property value

public abstract GSSCredential getGSSCredential ()

Get GSS Delegation Credential for Kerberos Authentication mode

Returns
  • GSS Delegation Credential for Kerberos Authentication mode

public abstract String getKey ()

Returns the unique key which identifies this session within its list. This key can be used with the getByKey method on WebIServerSessionList to retrieve this session. The key is not parsable and will only be consistent within a single collection, but the key is guaranteed to remain the same for an indefinite number of save/restore state operations.

Returns
  • A key which can be used to refer to this session within the collection.

public abstract String getLDAPDistinguishedName ()

Get LDAP Distinguished Name for Single Sign on authentication mode

Returns
  • LDAP Distinguished Name for Single Sign on authentication mode

public abstract long getLastAccessTime ()

Returns the last access time of the session.

Returns
  • The last access time of the session.

public abstract String getMessageID ()

public abstract String getOrgID ()

Gets the Usher organization/network ID associated with this session.

Returns
  • Usher organization/network ID.

public abstract SimpleList getOutOfComplianceLicenses (int[] levels)

Returns the list of out of compliance licenses (of required compliance levels) for the current user session. The invalid licenses are returned as SimpleList of WebLicenseDetails objects. If the returned list is of length 0, the licenses are valid.

Parameters
levels An integer array of compliance levels to be filtered on.
Returns
  • list of invalid licenses
Throws
WebObjectsException if there was an error in IServer while validating the licenses.

public abstract String getPartialURL ()

Returns the partial url set by setPartialURL(String)

public abstract String getProjectID ()

Returns the project ID corresponding to the projectName that was set. If the projectName is not set, then null is returned

Returns
  • The current setting of the projectID property.
Throws
WebObjectsException} if there is an error while retrieving the ID
IllegalArgumentException if the projectName is not empty but invalid
WebObjectsException

public abstract String getProjectName ()

Returns the project name which will be logged into.

Returns
  • The current setting of the projectName property.

public abstract int getRegularWorkingSetSize ()

Returns the regular working set size which is currently set on the object. The regular working set size tells how many report/document executions which are not saved to inbox are kept alive on the Intelligence Server before deleting older ones.

Returns
  • The current value of the regular working set size.

public abstract String getResultCode ()

public abstract int getSearchWorkingSetSize ()

Returns the search working set size which is currently set on the object. The search working set size tells how many searches to keep alive on the Intelligence Server before deleting older ones.

Returns
  • The current value of the search working set size.

public abstract String getServerName ()

Returns the Intelligence Server name to be contacted when creating a session.

Returns
  • The current Intelligence Server name.

public abstract int getServerPort ()

Returns the Intelligence Server port which will be connected to when sending a request. If this value is 0, then the default port of 0x8888(34952 decimal) will be used.

Returns
  • The port which will be used upon contacting the Intelligence Server.

public abstract String getServerVersion ()

Returns the version of the Intelligence Server specified by the serverName and port properties.

Returns
  • The version of the Intelligence Server.
Throws
WebObjectsException Thrown if an error occurs upon retrieving this information.

public abstract int getSessionFlags ()

Returns the flag settings which will be used upon calling createSession or closeSession. This value will be the bitwise or(|) of values from EnumDSSXMLSessionFlags.

Note that the default value for this has changed in 8.0.2 to DssXmlSessionDeleteReadMsgsOnClose from the previous default of 0.

Returns
  • The current session flag value.

public abstract String getSessionKey ()

Get session key for mobile encryption

Returns
  • Session key for mobile encryption

public abstract String getTrustToken ()

Get Trust Token for Single Sign on authentication mode

Returns
  • Trust Token for Single Sign on authentication mode

public abstract Preferences getUserPreferences ()

public abstract UsherSessionHelper getUsherSessionHelper ()

public abstract String getWebVersion ()

Returns the version of the Web API which is being used.

Returns
  • The version of the Web API.

public abstract boolean isMDUser ()

Returns a boolean to indicate whether the user that this session corresponds to is an actual user persisted in the metadata. In cases like

this method will return false.

Returns
  • boolean to indicate whether the user that this session corresponds to is an actual user persisted in the metadata
Throws
WebObjectsException if there is an error while reading user information

public abstract void populate (WebIServerSession otherSession)

This method can be used to populate the current session with the information from the given session. This means that all properties of the given session will be copied into the given session. This method is primarily used when it is necessary to add a session to the list which comes from another list or an external source (such as an External Security Module). In this case, the foreign session can be added to the list by creating a new session in the list and calling populate on the new session, passing the foreign session. Note that when this method is called, all properties of the session it is called upon will be discarded.

Parameters
otherSession The session whose properties will be copied into the current session.

public abstract void resolveLocalesOnly (WebUserEntity oUserEntity)

Connects to the Intelligence Server to resolve the locales without creating a session.

Parameters
oUserEntity the user we want to apply

public abstract void resolveLocalesOnly ()

Connects to the Intelligence Server to resolve the locales without creating a session.

public abstract void setAccessToken (String accessToken)

Sets the two-step verification code

public abstract void setApplicationType (int applicationType)

Sets the application type to use when creating the session, from EnumDSSXMLApplicationType.}

Parameters
applicationType The application type to use for the session, from EnumDSSXMLApplicationType.

public abstract void setAuthMode (int authMode)

Sets the current setting of the authMode property, which determines the type of credentials used upon creating a session to the Intelligence Server.

Parameters
authMode The authMode setting to use, from EnumDSSXMLAuthModes.
See Also

public abstract void setClientID (String clientID)

Sets the value of the client identifier, which tells the Intelligence Server upon login the identifier of the client machine.

Parameters
clientID The value of client ID to send to the Server.
See Also

public abstract void setClientVersion (String clientVersion)

Sets the value of the client version, which tells the Intelligence Server upon login the version of the client.

Parameters
clientVersion The value of client version to send to the Server.

public abstract void setConfSessionID (String confSessionID)

Set the configuration session ID. This configuration session ID will be used to create project session without user name and password, when auth mode is set to DssXmlAuthSessionID

public abstract void setExtraParams (String value)

public abstract void setExtraProperty (String name, String value)

Set extra property on this session object. The properties are only present on web server side and will never be sent to backend. NOTE: the properties set here will be serialized to the state if the persistent level is EnumWebPersistableState.TYPICAL_STATE_INFO or greater. Please carefully use this method, in case the session state is getting too long.

Parameters
name property name
value property value

public abstract void setGSSCredential (GSSCredential credential)

Set GSS Delegation Credential for Kerberos Authentication mode

Parameters
credential GSS Delegation Credential for Kerberos Authentication mode

public abstract void setLDAPDistinguishedName (String LDAPDN)

Set LDAP Distinguished Name for Single Sign on authentication mode

Parameters
LDAPDN LDAP Distinguished Name for Single Sign on authentication mode

public abstract void setLastMsgID (String lastMsgID)

set the last message ID

public abstract void setOrgID (String orgID)

Sets the Usher organization/network ID. This ID maybe different from the usher organization/network ID configured at Iserver side.

public abstract void setPartialURL (String url)

Defines partial url that will used to replace the {&WEBSERVER} macro whereever it is used The macro is used , for instance, in Report Services document. The partial url is not maintained in the state It needs to be set for every instance of the session

public abstract void setProjectID (String dssID)

Sets the project DSS ID which will be logged into.

Parameters
dssID The project to log into.

public abstract void setProjectName (String projectName)

Sets the project name which will be logged into.

Parameters
projectName The project to log into.
See Also

public abstract void setRegularWorkingSetSize (int newRegularWorkingSetSize)

Sets the regular working set size. The regular working set size tells how many report/document executions which are not saved to inbox are kept alive on the Intelligence Server before deleting older ones. To reconfigure this setting after a session has already obtained, updateSessionParameters() needs to be called.

Parameters
newRegularWorkingSetSize The new value for the regular working set size.

public abstract void setSearchWorkingSetSize (int newSearchWorkingSetSize)

Sets the search working set size. The search working set size tells how many search executions are kept alive on the Intelligence Server before deleting older ones. To reconfigure this setting after a session has already obtained, updateSessionParameters() needs to be called.

Parameters
newSearchWorkingSetSize The new value for the search working set size.

public abstract void setServerName (String serverName)

Sets the Intelligence Server name to be contacted when creating a session.

Parameters
serverName The name of the Intelligence Server to be contacted.
See Also

public abstract void setServerPort (int portNumber)

Sets the Intelligence Server port which will be connected to when sending a request. If this value is 0, then the default port of 0x8888(34952 decimal) will be used.

Parameters
portNumber The port which should be used upon contacting the Intelligence Server.
See Also

public abstract void setSessionFlags (int newSessionFlags)

This value should be the bitwise or(|) of values from EnumDSSXMLSessionFlags. Sets the value to use for the session flags when creating a session (getSessionID()) or closing one (closeSession()). This setting may also be changed during a session via updateSessionParameters().

Parameters
newSessionFlags The session flag value to be used.

public abstract void setSessionKey (String sessionKey)

Set session key for mobile encryption

Parameters
sessionKey Session key for mobile encryption

public abstract void setToken (Object token)

Sets the token.

Parameters
token The token value.

public abstract void setTrustToken (String token)

Set Trust Token for Single Sign on authentication mode

Parameters
token Trust Token for Single Sign on authentication mode

public abstract void setTwoStepVerificationCode (String twoStepVerificationCode)

Sets the two-step verification code

public abstract void updateSessionParameters ()

Normally, the following parameters are established during session creation. This method must be called if they are modified after session creation in order for the Intelligence Server to recognize the updated values.

Throws
WebObjectsException thrown if there was a problem readjusting.