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 the WebObjectsFactory object, and uses the WebIServerSession object associated with that factory.
    Since:
    MicroStrategy Web 7.5.2
    • 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, from EnumDSSXMLLicenseComplianceCategory.
        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, from EnumDSSXMLLicenseComplianceCategory.
        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, an null object will be returned.
        Parameters:
        category - The category of compliance to check, from EnumDSSXMLLicenseComplianceCategory.
        Returns:
        null when there is no out of compliance. Otherwise, a WebLicenseDetails 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 the CPULicenseDetails 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.
      • 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, from EnumDSSXMLLicenseType.
        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,
                                                            boolean includeLDAPUsersForAuditing)
                                                     throws WebObjectsException
        Returns a WebPrivilegeCategories 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 from EnumDSSXMLAuditorTypes. 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
        auditorType - the auditor type from EnumDSSXMLAuditorTypes}
        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 the BatchLicenseAudit 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 the BatchLicenseAudit 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 from EnumDSSXMLAuditorTypes
        Returns:
        the BatchLicenseAudit object with the specified auditing handle ID.
        Throws:
        WebObjectsException - thrown if an error occurs.
        Since:
        MicroStrategy Web 9.2.0