Interface LicenseSource
-
public interface LicenseSource
The LicenseSource interface is the source interface for all license auditing-related functionality. It contains methods to determine overall I-Server compliance, CPU compliance, named user compliance, audit users, and retrieve full privilege lists for users sorted by license type. This interface is obtained from theWebObjectsFactory
object, and uses theWebIServerSession
object associated with that factory.- Since:
- MicroStrategy Web 7.5.2
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description UserLicenseAudit
auditUsers(WebUserEntity group)
Audits the given user groups.BatchLicenseAudit
getBatchAudit(int auditID, int blockCount)
Returns theBatchLicenseAudit
object with the specified auditing handle ID.BatchLicenseAudit
getBatchAudit(int auditID, int blockCount, int auditorType)
Returns theBatchLicenseAudit
object with the specified auditing handle ID and auditor type.WebLicenseDetails
GetComplianceLevel(int category)
Checks compliance level and days of expiration for specified category.CPULicenseDetails
getCPUCompliance()
This method evaluates the CPU compliance status of the Intelligence Server that the session is created on.NamedUserLicense[]
getNamedUserCompliance()
Returns the current named user compliance of the Intelligence Server.int[]
getPrivilegesForLicenseType(int type)
Returns the list of privileges which belong to the given license type.java.lang.String
getServerComplianceDetail(int category)
If the Intelligence Server is out of compliance, then this method will return a string describing why it is out of compliance.WebPrivilegeCategories
getUserCategorizedPrivileges(WebUserEntity user)
Returns aWebPrivilegeCategories
object, which contains all the privileges for the given user and their sources, sorted by license type.WebPrivilegeCategories
getUserCategorizedPrivileges(WebUserEntity user, boolean includeLDAPUsersForAuditing)
Returns aWebPrivilegeCategories
object, which contains all the privileges for the given user and their sources, sorted by license type.boolean
isServerCompliant(int category)
Returns whether the Intelligence Server is out of compliance in any way.BatchLicenseAudit
newBatchAudit(WebUserEntity group, int blockCount)
Starts a new batch auditing operation.BatchLicenseAudit
newBatchAudit(WebUserEntity group, int blockCount, int auditHandle)
Starts a new batch auditing operation, which can reuse a pre-existing auditor.BatchLicenseAudit
newBatchAudit(WebUserEntity group, int blockCount, int auditHandle, int auditorType)
Starts a new batch auditing operation, which can reuse a pre-existing auditor, and can also specify an auditor type fromEnumDSSXMLAuditorTypes
.void
refreshCompliance()
Forces the Intelligence Server to refresh all compliance information that it has gathered - it will recalculate all licenses used and compare them with the existing licenses and update the internal data structures on the server with that information.
-
-
-
Method Detail
-
isServerCompliant
boolean isServerCompliant(int category) throws WebObjectsException
Returns whether the Intelligence Server is out of compliance in any way. If this is true, then getServerComplianceDetail will not return a useful result; if it is false, then getServerComplianceDetail will contain a reason why the server is not in compliance.- Parameters:
category
- The category of compliance to check, fromEnumDSSXMLLicenseComplianceCategory
.- Returns:
- True if the server is in compliance, false if it is not.
- Throws:
WebObjectsException
- Thrown if an error occurs.
-
getServerComplianceDetail
java.lang.String getServerComplianceDetail(int category) throws WebObjectsException
If the Intelligence Server is out of compliance, then this method will return a string describing why it is out of compliance.- Parameters:
category
- The category of compliance to check, fromEnumDSSXMLLicenseComplianceCategory
.- Returns:
- A string explaining why the server is out of compliance, or null if the server is not in compliance.
- Throws:
WebObjectsException
- Thrown if an error occurs.
-
GetComplianceLevel
WebLicenseDetails GetComplianceLevel(int category) throws WebObjectsException
Checks compliance level and days of expiration for specified category. When there there is out of compliance for the specified category, the returned WebLicenseDetails will record the out of compliance level and days information. NOTE that the license type information in WebLicneseDetails is not applicable in this case. When there is no out of compliance for the specified category, annull
object will be returned.- Parameters:
category
- The category of compliance to check, fromEnumDSSXMLLicenseComplianceCategory
.- Returns:
null
when there is no out of compliance. Otherwise, aWebLicenseDetails
returned for compliance leve and days information.- Throws:
WebObjectsException
- if there was an error in IServer while validating the licenses.- Since:
- MicroStrategy Web 8.0.0
-
getCPUCompliance
CPULicenseDetails getCPUCompliance() throws WebObjectsException
This method evaluates the CPU compliance status of the Intelligence Server that the session is created on. This call will return theCPULicenseDetails
interface, which will contain the details of the CPU compliance status.- Returns:
- An instance of the
CPULicenseDetails
interface containing the information about CPU license compliance. - Throws:
WebObjectsException
- Thrown if an error occurs.
-
getNamedUserCompliance
NamedUserLicense[] getNamedUserCompliance() throws WebObjectsException
Returns the current named user compliance of the Intelligence Server. This is presented as aSimpleList
containingNamedUserLicense
objects.- Returns:
- An array containing
NamedUserLicense
objects, which can be used to determine the named user licensing of the server. - Throws:
WebObjectsException
- Thrown if an error occurs.
-
auditUsers
UserLicenseAudit auditUsers(WebUserEntity group) throws WebObjectsException
Audits the given user groups. The result of the audit will be returned as aUserLicenseAudit
interface.- Parameters:
group
- The group to audit. All users in this group will be audited.- Returns:
- A
UserLicenseAudit
interface, which can be used to examine the result of the audit. - Throws:
WebObjectsException
- Thrown if an error occurs.
-
getPrivilegesForLicenseType
int[] getPrivilegesForLicenseType(int type) throws WebObjectsException
Returns the list of privileges which belong to the given license type.- Parameters:
type
- The license type to return the privileges for, fromEnumDSSXMLLicenseType
.- Returns:
- An array of ints, containing the privileges in the given license type.
- Throws:
WebObjectsException
- Thrown if an error occurs.
-
getUserCategorizedPrivileges
WebPrivilegeCategories getUserCategorizedPrivileges(WebUserEntity user) throws WebObjectsException
Returns aWebPrivilegeCategories
object, which contains all the privileges for the given user and their sources, sorted by license type.- Parameters:
user
- The user object to get the full privilege list for.- Returns:
- An object containing the privileges sorted by license type.
- Throws:
WebObjectsException
- Thrown if an error occurs.
-
getUserCategorizedPrivileges
WebPrivilegeCategories getUserCategorizedPrivileges(WebUserEntity user, boolean includeLDAPUsersForAuditing) throws WebObjectsException
Returns aWebPrivilegeCategories
object, which contains all the privileges for the given user and their sources, sorted by license type.- Parameters:
user
- The user object to get the full privilege list for.includeLDAPUsersForAuditing
- The boolean flag to indicate if we need to include LDAP users.- Returns:
- An object containing the privileges sorted by license type.
- Throws:
WebObjectsException
- Thrown if an error occurs.
-
refreshCompliance
void refreshCompliance() throws WebObjectsException
Forces the Intelligence Server to refresh all compliance information that it has gathered - it will recalculate all licenses used and compare them with the existing licenses and update the internal data structures on the server with that information.- Throws:
WebObjectsException
- Thrown if an error occurs when requesting the refresh.
-
newBatchAudit
BatchLicenseAudit newBatchAudit(WebUserEntity group, int blockCount) throws WebObjectsException
Starts a new batch auditing operation. This is an asynchronous operation.- Parameters:
group
- the user or user group to be audited.blockCount
- the number of users to be audited.- Returns:
- a
BatchLicenseAudit
object containing the first auditing result and a new auditing handle for further batch auditing as needed. - Throws:
WebObjectsException
- thrown if an error occurs during auditing.- Since:
- MicroStrategy Web 8.0.2
-
newBatchAudit
BatchLicenseAudit newBatchAudit(WebUserEntity group, int blockCount, int auditHandle) throws WebObjectsException
Starts a new batch auditing operation, which can reuse a pre-existing auditor. This is an asynchronous operation.- Parameters:
group
- the user or user group to be audited.blockCount
- the number of users to be audited.auditHandle
- the int handle of an existing auditor- Returns:
- a
BatchLicenseAudit
object containing the first auditing result and a new auditing handle for further batch auditing as needed. - Throws:
WebObjectsException
- thrown if an error occurs during auditing or if auditHandle refers to non-exisiting auditor- Since:
- MicroStrategy Web 9.0.0
-
newBatchAudit
BatchLicenseAudit newBatchAudit(WebUserEntity group, int blockCount, int auditHandle, int auditorType) throws WebObjectsException
Starts a new batch auditing operation, which can reuse a pre-existing auditor, and can also specify an auditor type fromEnumDSSXMLAuditorTypes
. This is an asynchronous operation.- Parameters:
group
- the user or user group to be audited.blockCount
- the number of users to be audited.auditHandle
- the int handle of an existing auditorauditorType
- the auditor type fromEnumDSSXMLAuditorTypes
}- Returns:
- a
BatchLicenseAudit
object containing the first auditing result and a new auditing handle for further batch auditing as needed. - Throws:
WebObjectsException
- thrown if an error occurs during auditing or if auditHandle refers to non-exisiting auditor- Since:
- MicroStrategy Web 9.2.0
-
getBatchAudit
BatchLicenseAudit getBatchAudit(int auditID, int blockCount) throws WebObjectsException
Returns theBatchLicenseAudit
object with the specified auditing handle ID. This is used when getting results of a currently processing audit.- Parameters:
auditID
- a batch auditing handle ID.blockCount
- the number of users to be audited.- Returns:
- the
BatchLicenseAudit
object with the specified auditing handle ID. - Throws:
WebObjectsException
- thrown if an error occurs.- Since:
- MicroStrategy Web 8.0.2
-
getBatchAudit
BatchLicenseAudit getBatchAudit(int auditID, int blockCount, int auditorType) throws WebObjectsException
Returns theBatchLicenseAudit
object with the specified auditing handle ID and auditor type. This is used when getting results of a currently processing audit.- Parameters:
auditID
- a batch auditing handle ID.blockCount
- the number of users to be audited.auditorType
- the auditor type fromEnumDSSXMLAuditorTypes
- Returns:
- the
BatchLicenseAudit
object with the specified auditing handle ID. - Throws:
WebObjectsException
- thrown if an error occurs.- Since:
- MicroStrategy Web 9.2.0
-
-