# Managed Object - ProfileComplianceManager(vim.profile.ComplianceManager)

Property of
  ServiceContent
See also
  ComplianceResult, ManagedEntity, Profile, ProfileExpressionMetadata
Since
  vSphere API 4.0

## Managed Object Description

Interface handling the Compliance aspects of entities.

Properties

Name | Type | Description
--- | --- | ---
None

Methods

Methods defined in this Managed Object
CheckCompliance_Task, ClearComplianceStatus, QueryComplianceStatus, QueryExpressionMetadata

# CheckCompliance_Task(checkCompliance)

Check compliance of an entity against a Profile.

Required Privileges
  System.View

Parameters

Name | Type | Description
--- | --- | ---
_this | ManagedObjectReference | A reference to the ProfileComplianceManager used to make the method call.
profile* P | ManagedObjectReference[] to a Profile[] | If specified, check compliance against the specified profiles. If not specified, use the profiles associated with the entities. If both Profiles and Entities are specified, Check the compliance of each Entity against each of the profile specified. For more information, look at the KMap below. P represents if Profile is specified. E represents if Entity is specified.
                P                        ^P
      ---------------------------------------------------
      | Check compliance      |  Profiles associated    |
     E|  of each entity       |   with the specified    |
      |  against each of the  |   entity will be used   |
      |  profiles specified.  |   for checking          |
      |                       |   compliance.           |
      |                       |                         |
      |                       |                         |
      ---------------------------------------------------
      | All entities          |   InvalidArgument       |
      |  associated with the  |   Exception is thrown.  |
      |  profile are checked. |                         |
    ^E|                       |                         |
      |                       |                         |
      |                       |                         |
      |                       |                         |
      ---------------------------------------------------
Since vSphere API 4.0
entity* P | ManagedObjectReference[] to a ManagedEntity[] | If specified, the compliance check is done against this entity. Since vSphere API 4.0

*Need not be set P Required privilege - see tooltip for details

Return Value

Type | Description
--- | ---
ManagedObjectReference to a Task |

Faults

Type | Description
--- | ---
RuntimeFault | Thrown if any type of runtime fault is thrown that is not covered by the other faults; for example, a communication error.

Events

Type
None

# ClearComplianceStatus(clearComplianceStatus)

Clear the saved ComplianceResult based on profile and entity filtering criteria.

Required Privileges
  Profile.Clear

Parameters

Name | Type | Description
--- | --- | ---
_this | ManagedObjectReference | A reference to the ProfileComplianceManager used to make the method call.
profile* P | ManagedObjectReference[] to a Profile[] | If specified, clear the ComplianceResult related to the Profile. Since vSphere API 4.0
entity* P | ManagedObjectReference[] to a ManagedEntity[] | If specified, clear the ComplianceResult related to the entity. If profile and entity are not specified, all the ComplianceResults will be cleared. Since vSphere API 4.0

*Need not be set P Required privilege - see tooltip for details

Return Value

Type | Description
--- | ---
None

Faults

Type | Description
--- | ---
RuntimeFault | Thrown if any type of runtime fault is thrown that is not covered by the other faults; for example, a communication error.

Events

Type
None

Show WSDL type definition
<element xmlns="http://www.w3.org/2001/XMLSchema" xmlns:vsan="urn:vsan" name="ClearComplianceStatus" type="vsan:ClearComplianceStatusRequestType"/> <element xmlns="http://www.w3.org/2001/XMLSchema" xmlns:vsan="urn:vsan" name="ClearComplianceStatusResponse"> <complexType/> </element>

# QueryComplianceStatus(queryComplianceStatus)

Query the compliance status based on Profile and Entity filter.

Required Privileges
  System.View

Parameters

Name | Type | Description
--- | --- | ---
_this | ManagedObjectReference | A reference to the ProfileComplianceManager used to make the method call.
profile* P | ManagedObjectReference[] to a Profile[] | If specified, compliance result for the specified profiles will be returned. This acts like a filtering criteria for the ComplianceResults based on specified profiles. Since vSphere API 4.0
entity* P | ManagedObjectReference[] to a ManagedEntity[] | If specified, compliance results for these entities will be returned. This acts like a filtering criteria for the ComplianceResults based on entities. Since vSphere API 4.0

*Need not be set P Required privilege - see tooltip for details

Return Value

Type | Description
--- | ---
ComplianceResult[] | ComplianceResult. ComplianceResult information may not be available for all the entities. If the ComplianceResult is not available already, a new ComplianceCheck will not be triggered.

Faults

Type | Description
--- | ---
RuntimeFault | Thrown if any type of runtime fault is thrown that is not covered by the other faults; for example, a communication error.

Events

Type
None

Show WSDL type definition
<element xmlns="http://www.w3.org/2001/XMLSchema" xmlns:vsan="urn:vsan" name="QueryComplianceStatus" type="vsan:QueryComplianceStatusRequestType"/> <element xmlns="http://www.w3.org/2001/XMLSchema" xmlns:vsan="urn:vsan" name="QueryComplianceStatusResponse"> <complexType> <sequence> <element name="returnval" type="vsan:ComplianceResult" minOccurs="0" maxOccurs="unbounded"/> </sequence> </complexType> </element>

# QueryExpressionMetadata(queryExpressionMetadata)

Query the metadata for the expressions.

Required Privileges
  System.View

Parameters

Name | Type | Description
--- | --- | ---
_this | ManagedObjectReference | A reference to the ProfileComplianceManager used to make the method call.
expressionName* P | xsd:string[] | Names of the Expressions for which metadata is requested. If expressionNames are not specified, metadata for all known expressions is returned Since vSphere API 4.0
profile* P | ManagedObjectReference to a Profile | Base profile whose context needs to be used during the operation Since vSphere API 4.0

*Need not be set P Required privilege - see tooltip for details

Return Value

Type | Description
--- | ---
ProfileExpressionMetadata[] |

Faults

Type | Description
--- | ---
RuntimeFault | Thrown if any type of runtime fault is thrown that is not covered by the other faults; for example, a communication error.

Events

Type
None

Show WSDL type definition
<element xmlns="http://www.w3.org/2001/XMLSchema" xmlns:vsan="urn:vsan" name="QueryExpressionMetadata" type="vsan:QueryExpressionMetadataRequestType"/> <element xmlns="http://www.w3.org/2001/XMLSchema" xmlns:vsan="urn:vsan" name="QueryExpressionMetadataResponse"> <complexType> <sequence> <element name="returnval" type="vsan:ProfileExpressionMetadata" minOccurs="0" maxOccurs="unbounded"/> </sequence> </complexType> </element>