Package com.microstrategy.web.objects
Interface WebProjectSource
-
public interface WebProjectSource
The WebProjectSource object is used to execute project-related tasks. It can be obtained fromWebObjectsFactory
, and internally it will be associated with that factory. From the associatedWebObjectsFactory
, this source will retrieve neccessay information needed for performing its task, especially theWebIServerSession
associated with the factory.It acts as a source for retrieving list of projects and project flags. Note that the getProjects method will return those projects that are loaded on the server, while getAccessibleProjects will use the credentials set on the
WebIServerSession
object to return only those projects that the user can login to successfully. getRepositoryProjects will return all projects in the repository, regardless of whether they are loaded or not; this method is only useful for server administration.- Since:
- MicroStrategy Web 7.3.1 or earlier
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description boolean
checkPrivilege(java.lang.String projectDSSID, int privilegeType)
Check the privilege based on the project.WebProjectInstances
getAccessibleProjects()
Returns theWebProjectInstances
object containing only those projects that the user can login to.WebProjectInstances
getAccessibleProjectsInCluster()
Return#getAccessibleProjectsInCluster(boolean)
with refresh set to true.WebProjectInstances
getAllProjectsInCluster()
Returns theWebProjectInstances
object containing all projects in cluster.WebProjectCreator
getProjectCreator()
Returns aWebProjectCreator
object which can be used to create a project on the IServerint
getProjectFlags()
This is reserved for future use.WebPropertySet
getProjectProperties(java.lang.String propertySetName)
returns the project properties for a given property set name.WebProjectInstances
getProjects()
Returns theWebProjectInstances
object containing all projects that are loaded on the server.WebProjectInstances
getProjects(boolean fromIServer)
Returns theWebProjectInstances
object containing all projects that are loaded on the server.WebProjectInstances
getProjectsInCluster()
Returns theWebProjectInstances
object containing all projects that are loaded on any server in cluster.WebProjectStatus
getProjectStatus()
This method assumes that the session associated with this project source corresponds to a valid project The status of this project is returnedWebPromptCustomStyles
getPromptCustomStyles()
Returns the prompt custom styles for this projectWebProjectInstances
getRepositoryProjects()
Returns theWebProjectInstances
object containing all projects on the server, regardless of whether they are loaded or not.void
refreshSQLEngineSchema(java.lang.String sessionID)
Refresh SQL Engine schema for all nodes in the connected cluster.void
saveProjectProperties(WebPropertySet wps)
Used to write back updated properties corresponding to property set wps that were retrieved usinggetProjectProperties(String)
void
setProjectFlags(int flags)
This is reserved for future use.void
updateProjectsInCluster()
Cause the Intelligence Servers in cluster to load/unload projects according to the latest asymmetric clustering map.
-
-
-
Method Detail
-
getProjects
WebProjectInstances getProjects() throws WebObjectsException
Returns theWebProjectInstances
object containing all projects that are loaded on the server. Note that the credentials to use for this call come from theWebIServerSession
object associated with theWebObjectsFactory
object that this object came from. The credentails include: server name and port number. These credentails need to be set up correctly onWebIServerSession
before calling this method.- Returns:
WebProjectInstances
object which is a collection of all loaded projects on the specific intelligence server (corresponding to the session).- Throws:
WebObjectsException
- Thrown if there is an error retrieving the list.
-
getProjects
WebProjectInstances getProjects(boolean fromIServer) throws WebObjectsException
Returns theWebProjectInstances
object containing all projects that are loaded on the server. Note that the credentials to use for this call come from theWebIServerSession
object associated with theWebObjectsFactory
object that this object came from. The credentails include: server name and port number. These credentails need to be set up correctly onWebIServerSession
before calling this method.- Parameters:
fromIServer
- boolean used to determine whetherWebProjectInstances
should come from IServer or Cache- Returns:
WebProjectInstances
object which is a collection of all loaded projects on the specific intelligence server (corresponding to the session).- Throws:
WebObjectsException
- Thrown if there is an error retrieving the list.- Since:
- MicroStrategy Web 9.0.0
-
getProjectsInCluster
WebProjectInstances getProjectsInCluster() throws WebObjectsException
Returns theWebProjectInstances
object containing all projects that are loaded on any server in cluster. Note that the credentials to use for this call come from theWebIServerSession
object associated with theWebObjectsFactory
object that this object came from. The credentails include: server name and port number. These credentails need to be set up correctly onWebIServerSession
before calling this method.- Returns:
WebProjectInstances
object which is a collection of all loaded projects in the cluster of the specific intelligence server (corresponding to the session).- Throws:
WebObjectsException
- Thrown if there is an error retrieving the list.- Since:
- MicroStrategy Web 8.0.0
-
getAllProjectsInCluster
WebProjectInstances getAllProjectsInCluster() throws WebObjectsException
Returns theWebProjectInstances
object containing all projects in cluster. Note that the credentials to use for this call come from theWebIServerSession
object associated with theWebObjectsFactory
object that this object came from. The credentails include: server name and port number. These credentails need to be set up correctly onWebIServerSession
before calling this method.- Returns:
WebProjectInstances
object which is a collection of all projects in the cluster of the specific intelligence server (corresponding to the session).- Throws:
WebObjectsException
- Thrown if there is an error retrieving the list.- Since:
- MicroStrategy Web Polaris
-
getAccessibleProjects
WebProjectInstances getAccessibleProjects() throws WebObjectsException
Returns theWebProjectInstances
object containing only those projects that the user can login to. Note that the credentials to use for this call come from theWebIServerSession
object associated with theWebObjectsFactory
object that this object came from. The credentials include: login name, password, authentication mode, server name and port number. These credentials need to be set up correctly onWebIServerSession
before calling this method.- Returns:
WebProjectInstances
object with the list of all projects that the current user has access to.- Throws:
WebObjectsException
- Thrown if there is an error retrieving the list.
-
getAccessibleProjectsInCluster
WebProjectInstances getAccessibleProjectsInCluster() throws WebObjectsException
Return#getAccessibleProjectsInCluster(boolean)
with refresh set to true.- Throws:
WebObjectsException
- Since:
- MicroStrategy Web 8.0.0
- See Also:
getAccessibleProjectsInCluster()
-
getProjectFlags
int getProjectFlags()
This is reserved for future use. It has no effect right now. There is no enumeration associated with the project flags at this time.- Returns:
- integer indicating the project flags that are set. This is reserved for future use.
-
setProjectFlags
void setProjectFlags(int flags)
This is reserved for future use. It has no effect right now. There is no enumeration associated with the project flags at this time.- Parameters:
flags
- integer argument specifying the project flags. This is reserved for future use.
-
getProjectStatus
WebProjectStatus getProjectStatus() throws WebObjectsException
This method assumes that the session associated with this project source corresponds to a valid project The status of this project is returned- Returns:
- the
WebProjectStatus
for the project specified and returns null if properties needed to read the status information do not exist - Throws:
WebObjectsException
- if there is an error while reading the properties
-
getRepositoryProjects
WebProjectInstances getRepositoryProjects() throws WebObjectsException
Returns theWebProjectInstances
object containing all projects on the server, regardless of whether they are loaded or not. Note this call uses session ID come from theWebIServerSession
object associated with theWebObjectsFactory
object that this object came from. A valid session ID must be created inWebIServerSession
before calling this method.- Returns:
WebProjectInstances
object which is a collection of all projects on the specific intelligence server (corresponding to the session).- Throws:
WebObjectsException
- Thrown if there is an error retrieving the list.- Since:
- MicroStrategy Web 7.5.0
-
getProjectProperties
WebPropertySet getProjectProperties(java.lang.String propertySetName) throws WebObjectsException
returns the project properties for a given property set name. Note that these properties are returned from a cache and should be used for read-only purposes. In order to write back updated properties, please usesaveProjectProperties(WebPropertySet)
- Parameters:
propertySetName
- the property set name- Returns:
- collection of properties as a WebPropertySet.
- Throws:
WebObjectsException
- if error was encountered on IServer while retrieving the properties.- Since:
- MicroStrategy Web 8.0.0
-
saveProjectProperties
void saveProjectProperties(WebPropertySet wps) throws WebObjectsException
Used to write back updated properties corresponding to property set wps that were retrieved usinggetProjectProperties(String)
- Parameters:
wps
-- Throws:
WebObjectsException
- Since:
- MicroStrategy Web 8.0.2
-
updateProjectsInCluster
void updateProjectsInCluster() throws WebObjectsException
Cause the Intelligence Servers in cluster to load/unload projects according to the latest asymmetric clustering map.- Throws:
WebObjectsException
- Since:
- MicroStrategy Web 8.0.0
-
checkPrivilege
boolean checkPrivilege(java.lang.String projectDSSID, int privilegeType) throws WebObjectsException
Check the privilege based on the project.- Parameters:
projectDSSID
- - project DSS ID to check.privilegeType
- - value fromEnumDSSXMLPrivilegeTypes
- Returns:
- true if the privilege is enabled
- Throws:
WebObjectsException
- if there is any error while retrieving privileges- Since:
- MicroStrategy Web 9.0.0
-
getPromptCustomStyles
WebPromptCustomStyles getPromptCustomStyles() throws WebObjectsException, java.lang.IllegalArgumentException
Returns the prompt custom styles for this project- Returns:
- The
WebPromptCustomStyles
for this project. Can be used for retrieving, editing the current custom styles defined for this project - Throws:
WebObjectsException
- Thrown when error happens during the retrieving.java.lang.IllegalArgumentException
- Thrown when error happens during the retrieving.- Since:
- MicroStrategy Web 9.0.0
-
getProjectCreator
WebProjectCreator getProjectCreator()
Returns aWebProjectCreator
object which can be used to create a project on the IServer- Returns:
WebProjectCreator
- Since:
- MicroStrategy Web 9.0.0
-
refreshSQLEngineSchema
void refreshSQLEngineSchema(java.lang.String sessionID) throws WebObjectsException
Refresh SQL Engine schema for all nodes in the connected cluster. This is required when COM schema is updated in MD- Parameters:
sessionID
- - session DSSID- Throws:
WebObjectsException
-
-