Share via


PolicyIdentity Class

Definition

[System.ComponentModel.TypeConverter(typeof(Microsoft.Azure.PowerShell.Cmdlets.Policy.Models.PolicyIdentityTypeConverter))]
public class PolicyIdentity : Microsoft.Azure.PowerShell.Cmdlets.Policy.Models.IPolicyIdentity
[<System.ComponentModel.TypeConverter(typeof(Microsoft.Azure.PowerShell.Cmdlets.Policy.Models.PolicyIdentityTypeConverter))>]
type PolicyIdentity = class
    interface IPolicyIdentity
    interface IJsonSerializable
Public Class PolicyIdentity
Implements IPolicyIdentity
Inheritance
PolicyIdentity
Attributes
Implements

Constructors

PolicyIdentity()

Creates an new PolicyIdentity instance.

Properties

Id

Resource identity path

ManagementGroupId

The ID of the management group.

ManagementGroupName

The name of the management group. The name is case insensitive.

ParentResourcePath

The parent resource path. Use empty string if there is none.

PolicyAssignmentId

The ID of the policy assignment to delete. Use the format '{scope}/providers/Microsoft.Authorization/policyAssignments/{policyAssignmentName}'.

PolicyAssignmentName

The name of the policy assignment to delete.

PolicyDefinitionName

The name of the policy definition to create.

PolicyDefinitionVersion

The policy definition version. The format is x.y.z where x is the major version number, y is the minor version number, and z is the patch number

PolicyExemptionName

The name of the policy exemption to delete.

PolicySetDefinitionName

The name of the policy set definition to create.

ResourceGroupName

The name of the resource group that contains policy assignments.

ResourceName

The name of the resource.

ResourceProviderNamespace

The namespace of the resource provider. For example, the namespace of a virtual machine is Microsoft.Compute (from Microsoft.Compute/virtualMachines)

ResourceType

The resource type name. For example the type name of a web app is 'sites' (from Microsoft.Web/sites).

Scope

The scope of the policy assignment. Valid scopes are: management group (format: '/providers/Microsoft.Management/managementGroups/{managementGroup}'), subscription (format: '/subscriptions/{subscriptionId}'), resource group (format: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}', or resource (format: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/[{parentResourcePath}/]{resourceType}/{resourceName}'

SubscriptionId

The ID of the target subscription. The value must be an UUID.

Methods

DeserializeFromDictionary(IDictionary)

Deserializes a IDictionary into an instance of PolicyIdentity.

DeserializeFromPSObject(PSObject)

Deserializes a PSObject into an instance of PolicyIdentity.

FromJson(JsonNode)

Deserializes a JsonNode into an instance of Microsoft.Azure.PowerShell.Cmdlets.Policy.Models.IPolicyIdentity.

FromJsonString(String)

Creates a new instance of PolicyIdentity, deserializing the content from a json string.

ToJson(JsonObject, SerializationMode)

Serializes this instance of PolicyIdentity into a JsonNode.

ToJsonString()

Serializes this instance to a json string.

Applies to