Language

PolicyInsightsExtensions.GetPolicyStateQueryResults Method

Definition

Overloads

Name Description
GetPolicyStateQueryResults(ResourceGroupResource, PolicyStateType, PolicyQuerySettings, CancellationToken)

Queries policy states for the resources under the resource group.

GetPolicyStateQueryResults(ArmClient, ResourceIdentifier, PolicyStateType, PolicyQuerySettings, CancellationToken)

Queries policy states for the resource.

GetPolicyStateQueryResults(SubscriptionResource, PolicyStateType, PolicyQuerySettings, CancellationToken)

Queries policy states for the resources under the subscription.

GetPolicyStateQueryResults(SubscriptionPolicySetDefinitionResource, PolicyStateType, PolicyQuerySettings, CancellationToken)

Queries policy states for the subscription level policy set definition.

GetPolicyStateQueryResults(PolicyAssignmentResource, PolicyStateType, PolicyQuerySettings, CancellationToken)

Queries policy states for the policy assignment.

GetPolicyStateQueryResults(ManagementGroupResource, PolicyStateType, PolicyQuerySettings, CancellationToken)

Queries policy states for the resources under the management group.

GetPolicyStateQueryResults(SubscriptionPolicyDefinitionResource, PolicyStateType, PolicyQuerySettings, CancellationToken)

Queries policy states for the subscription level policy definition.

GetPolicyStateQueryResults(ResourceGroupResource, PolicyStateType, PolicyQuerySettings, CancellationToken)

Source:
PolicyInsightsExtensions.cs
Source:
PolicyInsightsExtensions.cs

Queries policy states for the resources under the resource group.

public static Azure.Pageable<Azure.ResourceManager.PolicyInsights.Models.PolicyState> GetPolicyStateQueryResults(this Azure.ResourceManager.Resources.ResourceGroupResource resourceGroupResource, Azure.ResourceManager.PolicyInsights.Models.PolicyStateType policyStateType, Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings policyQuerySettings = default, System.Threading.CancellationToken cancellationToken = default);
static member GetPolicyStateQueryResults : Azure.ResourceManager.Resources.ResourceGroupResource * Azure.ResourceManager.PolicyInsights.Models.PolicyStateType * Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings * System.Threading.CancellationToken -> Azure.Pageable<Azure.ResourceManager.PolicyInsights.Models.PolicyState>
<Extension()>
Public Function GetPolicyStateQueryResults (resourceGroupResource As ResourceGroupResource, policyStateType As PolicyStateType, Optional policyQuerySettings As PolicyQuerySettings = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Pageable(Of PolicyState)

Parameters

resourceGroupResource
ResourceGroupResource

The ResourceGroupResource instance the method will execute against.

policyStateType
PolicyStateType

The virtual resource under PolicyStates resource type. In a given time range, 'latest' represents the latest policy state(s), whereas 'default' represents all policy state(s).

policyQuerySettings
PolicyQuerySettings

Parameter group.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

A collection of PolicyState that may take multiple service requests to iterate over.

Exceptions

resourceGroupResource is null.

Applies to

GetPolicyStateQueryResults(ArmClient, ResourceIdentifier, PolicyStateType, PolicyQuerySettings, CancellationToken)

Source:
PolicyInsightsExtensions.cs
Source:
PolicyInsightsExtensions.cs

Queries policy states for the resource.

public static Azure.Pageable<Azure.ResourceManager.PolicyInsights.Models.PolicyState> GetPolicyStateQueryResults(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier scope, Azure.ResourceManager.PolicyInsights.Models.PolicyStateType policyStateType, Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings policyQuerySettings = default, System.Threading.CancellationToken cancellationToken = default);
static member GetPolicyStateQueryResults : Azure.ResourceManager.ArmClient * Azure.Core.ResourceIdentifier * Azure.ResourceManager.PolicyInsights.Models.PolicyStateType * Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings * System.Threading.CancellationToken -> Azure.Pageable<Azure.ResourceManager.PolicyInsights.Models.PolicyState>
<Extension()>
Public Function GetPolicyStateQueryResults (client As ArmClient, scope As ResourceIdentifier, policyStateType As PolicyStateType, Optional policyQuerySettings As PolicyQuerySettings = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Pageable(Of PolicyState)

Parameters

client
ArmClient

The ArmClient instance the method will execute against.

scope
ResourceIdentifier

The scope that the resource will apply against.

policyStateType
PolicyStateType

The virtual resource under PolicyStates resource type. In a given time range, 'latest' represents the latest policy state(s), whereas 'default' represents all policy state(s).

policyQuerySettings
PolicyQuerySettings

Parameter group.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

Exceptions

client is null.

Applies to

GetPolicyStateQueryResults(SubscriptionResource, PolicyStateType, PolicyQuerySettings, CancellationToken)

Source:
PolicyInsightsExtensions.cs
Source:
PolicyInsightsExtensions.cs

Queries policy states for the resources under the subscription.

public static Azure.Pageable<Azure.ResourceManager.PolicyInsights.Models.PolicyState> GetPolicyStateQueryResults(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.PolicyInsights.Models.PolicyStateType policyStateType, Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings policyQuerySettings = default, System.Threading.CancellationToken cancellationToken = default);
static member GetPolicyStateQueryResults : Azure.ResourceManager.Resources.SubscriptionResource * Azure.ResourceManager.PolicyInsights.Models.PolicyStateType * Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings * System.Threading.CancellationToken -> Azure.Pageable<Azure.ResourceManager.PolicyInsights.Models.PolicyState>
<Extension()>
Public Function GetPolicyStateQueryResults (subscriptionResource As SubscriptionResource, policyStateType As PolicyStateType, Optional policyQuerySettings As PolicyQuerySettings = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Pageable(Of PolicyState)

Parameters

subscriptionResource
SubscriptionResource

The SubscriptionResource instance the method will execute against.

policyStateType
PolicyStateType

The virtual resource under PolicyStates resource type. In a given time range, 'latest' represents the latest policy state(s), whereas 'default' represents all policy state(s).

policyQuerySettings
PolicyQuerySettings

Parameter group.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

A collection of PolicyState that may take multiple service requests to iterate over.

Exceptions

subscriptionResource is null.

Applies to

GetPolicyStateQueryResults(SubscriptionPolicySetDefinitionResource, PolicyStateType, PolicyQuerySettings, CancellationToken)

Source:
PolicyInsightsExtensions.cs
Source:
PolicyInsightsExtensions.cs

Queries policy states for the subscription level policy set definition.

public static Azure.Pageable<Azure.ResourceManager.PolicyInsights.Models.PolicyState> GetPolicyStateQueryResults(this Azure.ResourceManager.Resources.SubscriptionPolicySetDefinitionResource subscriptionPolicySetDefinitionResource, Azure.ResourceManager.PolicyInsights.Models.PolicyStateType policyStateType, Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings policyQuerySettings = default, System.Threading.CancellationToken cancellationToken = default);
static member GetPolicyStateQueryResults : Azure.ResourceManager.Resources.SubscriptionPolicySetDefinitionResource * Azure.ResourceManager.PolicyInsights.Models.PolicyStateType * Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings * System.Threading.CancellationToken -> Azure.Pageable<Azure.ResourceManager.PolicyInsights.Models.PolicyState>
<Extension()>
Public Function GetPolicyStateQueryResults (subscriptionPolicySetDefinitionResource As SubscriptionPolicySetDefinitionResource, policyStateType As PolicyStateType, Optional policyQuerySettings As PolicyQuerySettings = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Pageable(Of PolicyState)

Parameters

subscriptionPolicySetDefinitionResource
SubscriptionPolicySetDefinitionResource

The SubscriptionPolicySetDefinitionResource instance the method will execute against.

policyStateType
PolicyStateType

The virtual resource under PolicyStates resource type. In a given time range, 'latest' represents the latest policy state(s), whereas 'default' represents all policy state(s).

policyQuerySettings
PolicyQuerySettings

Parameter group.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

A collection of PolicyState that may take multiple service requests to iterate over.

Applies to

GetPolicyStateQueryResults(PolicyAssignmentResource, PolicyStateType, PolicyQuerySettings, CancellationToken)

Source:
PolicyInsightsExtensions.cs
Source:
PolicyInsightsExtensions.cs

Queries policy states for the policy assignment.

public static Azure.Pageable<Azure.ResourceManager.PolicyInsights.Models.PolicyState> GetPolicyStateQueryResults(this Azure.ResourceManager.Resources.PolicyAssignmentResource policyAssignmentResource, Azure.ResourceManager.PolicyInsights.Models.PolicyStateType policyStateType, Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings policyQuerySettings = default, System.Threading.CancellationToken cancellationToken = default);
static member GetPolicyStateQueryResults : Azure.ResourceManager.Resources.PolicyAssignmentResource * Azure.ResourceManager.PolicyInsights.Models.PolicyStateType * Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings * System.Threading.CancellationToken -> Azure.Pageable<Azure.ResourceManager.PolicyInsights.Models.PolicyState>
<Extension()>
Public Function GetPolicyStateQueryResults (policyAssignmentResource As PolicyAssignmentResource, policyStateType As PolicyStateType, Optional policyQuerySettings As PolicyQuerySettings = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Pageable(Of PolicyState)

Parameters

policyAssignmentResource
PolicyAssignmentResource

The PolicyAssignmentResource instance the method will execute against.

policyStateType
PolicyStateType

The virtual resource under PolicyStates resource type. In a given time range, 'latest' represents the latest policy state(s), whereas 'default' represents all policy state(s).

policyQuerySettings
PolicyQuerySettings

Parameter group.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

A collection of PolicyState that may take multiple service requests to iterate over.

Applies to

GetPolicyStateQueryResults(ManagementGroupResource, PolicyStateType, PolicyQuerySettings, CancellationToken)

Source:
PolicyInsightsExtensions.cs
Source:
PolicyInsightsExtensions.cs

Queries policy states for the resources under the management group.

public static Azure.Pageable<Azure.ResourceManager.PolicyInsights.Models.PolicyState> GetPolicyStateQueryResults(this Azure.ResourceManager.ManagementGroups.ManagementGroupResource managementGroupResource, Azure.ResourceManager.PolicyInsights.Models.PolicyStateType policyStateType, Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings policyQuerySettings = default, System.Threading.CancellationToken cancellationToken = default);
static member GetPolicyStateQueryResults : Azure.ResourceManager.ManagementGroups.ManagementGroupResource * Azure.ResourceManager.PolicyInsights.Models.PolicyStateType * Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings * System.Threading.CancellationToken -> Azure.Pageable<Azure.ResourceManager.PolicyInsights.Models.PolicyState>
<Extension()>
Public Function GetPolicyStateQueryResults (managementGroupResource As ManagementGroupResource, policyStateType As PolicyStateType, Optional policyQuerySettings As PolicyQuerySettings = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Pageable(Of PolicyState)

Parameters

managementGroupResource
ManagementGroupResource

The ManagementGroupResource instance the method will execute against.

policyStateType
PolicyStateType

The virtual resource under PolicyStates resource type. In a given time range, 'latest' represents the latest policy state(s), whereas 'default' represents all policy state(s).

policyQuerySettings
PolicyQuerySettings

Parameter group.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

A collection of PolicyState that may take multiple service requests to iterate over.

Exceptions

managementGroupResource is null.

Applies to

GetPolicyStateQueryResults(SubscriptionPolicyDefinitionResource, PolicyStateType, PolicyQuerySettings, CancellationToken)

Source:
PolicyInsightsExtensions.cs
Source:
PolicyInsightsExtensions.cs

Queries policy states for the subscription level policy definition.

public static Azure.Pageable<Azure.ResourceManager.PolicyInsights.Models.PolicyState> GetPolicyStateQueryResults(this Azure.ResourceManager.Resources.SubscriptionPolicyDefinitionResource subscriptionPolicyDefinitionResource, Azure.ResourceManager.PolicyInsights.Models.PolicyStateType policyStateType, Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings policyQuerySettings = default, System.Threading.CancellationToken cancellationToken = default);
static member GetPolicyStateQueryResults : Azure.ResourceManager.Resources.SubscriptionPolicyDefinitionResource * Azure.ResourceManager.PolicyInsights.Models.PolicyStateType * Azure.ResourceManager.PolicyInsights.Models.PolicyQuerySettings * System.Threading.CancellationToken -> Azure.Pageable<Azure.ResourceManager.PolicyInsights.Models.PolicyState>
<Extension()>
Public Function GetPolicyStateQueryResults (subscriptionPolicyDefinitionResource As SubscriptionPolicyDefinitionResource, policyStateType As PolicyStateType, Optional policyQuerySettings As PolicyQuerySettings = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Pageable(Of PolicyState)

Parameters

subscriptionPolicyDefinitionResource
SubscriptionPolicyDefinitionResource

The SubscriptionPolicyDefinitionResource instance the method will execute against.

policyStateType
PolicyStateType

The virtual resource under PolicyStates resource type. In a given time range, 'latest' represents the latest policy state(s), whereas 'default' represents all policy state(s).

policyQuerySettings
PolicyQuerySettings

Parameter group.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

A collection of PolicyState that may take multiple service requests to iterate over.

Applies to