class Azure::Policy::Mgmt::V2018_05_01::Models::PolicyAssignment

The policy assignment.

Attributes

description[RW]

@return [String] This message will be part of response in case of policy violation.

display_name[RW]

@return [String] The display name of the policy assignment.

id[RW]

@return [String] The ID of the policy assignment.

identity[RW]

@return [Identity] The managed identity associated with the policy assignment.

location[RW]

@return [String] The location of the policy assignment. Only required when utilizing managed identity.

metadata[RW]

@return The policy assignment metadata.

name[RW]

@return [String] The name of the policy assignment.

not_scopes[RW]

@return [Array<String>] The policy's excluded scopes.

parameters[RW]

@return Required if a parameter is used in policy rule.

policy_definition_id[RW]

@return [String] The ID of the policy definition or policy set definition being assigned.

scope[RW]

@return [String] The scope for the policy assignment.

sku[RW]

@return [PolicySku] The policy sku. This property is optional, obsolete, and will be ignored.

type[RW]

@return [String] The type of the policy assignment.

Public Class Methods

mapper() click to toggle source

Mapper for PolicyAssignment class as Ruby Hash. This will be used for serialization/deserialization.

# File lib/2018-05-01/generated/azure_mgmt_policy/models/policy_assignment.rb, line 64
def self.mapper()
  {
    client_side_validation: true,
    required: false,
    serialized_name: 'PolicyAssignment',
    type: {
      name: 'Composite',
      class_name: 'PolicyAssignment',
      model_properties: {
        display_name: {
          client_side_validation: true,
          required: false,
          serialized_name: 'properties.displayName',
          type: {
            name: 'String'
          }
        },
        policy_definition_id: {
          client_side_validation: true,
          required: false,
          serialized_name: 'properties.policyDefinitionId',
          type: {
            name: 'String'
          }
        },
        scope: {
          client_side_validation: true,
          required: false,
          serialized_name: 'properties.scope',
          type: {
            name: 'String'
          }
        },
        not_scopes: {
          client_side_validation: true,
          required: false,
          serialized_name: 'properties.notScopes',
          type: {
            name: 'Sequence',
            element: {
                client_side_validation: true,
                required: false,
                serialized_name: 'StringElementType',
                type: {
                  name: 'String'
                }
            }
          }
        },
        parameters: {
          client_side_validation: true,
          required: false,
          serialized_name: 'properties.parameters',
          type: {
            name: 'Object'
          }
        },
        description: {
          client_side_validation: true,
          required: false,
          serialized_name: 'properties.description',
          type: {
            name: 'String'
          }
        },
        metadata: {
          client_side_validation: true,
          required: false,
          serialized_name: 'properties.metadata',
          type: {
            name: 'Object'
          }
        },
        id: {
          client_side_validation: true,
          required: false,
          read_only: true,
          serialized_name: 'id',
          type: {
            name: 'String'
          }
        },
        type: {
          client_side_validation: true,
          required: false,
          read_only: true,
          serialized_name: 'type',
          type: {
            name: 'String'
          }
        },
        name: {
          client_side_validation: true,
          required: false,
          read_only: true,
          serialized_name: 'name',
          type: {
            name: 'String'
          }
        },
        sku: {
          client_side_validation: true,
          required: false,
          serialized_name: 'sku',
          type: {
            name: 'Composite',
            class_name: 'PolicySku'
          }
        },
        location: {
          client_side_validation: true,
          required: false,
          serialized_name: 'location',
          type: {
            name: 'String'
          }
        },
        identity: {
          client_side_validation: true,
          required: false,
          serialized_name: 'identity',
          type: {
            name: 'Composite',
            class_name: 'Identity'
          }
        }
      }
    }
  }
end