Class: Azure::RecoveryServicesBackup::Mgmt::V2019_06_15::Models::ProtectionPolicy

Inherits:
Object
  • Object
show all
Includes:
MsRestAzure
Defined in:
lib/2019-06-15/generated/azure_mgmt_recovery_services_backup/models/protection_policy.rb

Overview

Base class for backup policy. Workload-specific backup policies are derived from this class.

Constant Summary collapse

@@discriminatorMap =
Hash.new

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeProtectionPolicy

Returns a new instance of ProtectionPolicy.



24
25
26
# File 'lib/2019-06-15/generated/azure_mgmt_recovery_services_backup/models/protection_policy.rb', line 24

def initialize
  @backupManagementType = "ProtectionPolicy"
end

Instance Attribute Details

#backupManagementTypeObject

Returns the value of attribute backupManagementType.



28
29
30
# File 'lib/2019-06-15/generated/azure_mgmt_recovery_services_backup/models/protection_policy.rb', line 28

def backupManagementType
  @backupManagementType
end

#protected_items_countInteger

Returns Number of items associated with this policy.

Returns:

  • (Integer)

    Number of items associated with this policy.



31
32
33
# File 'lib/2019-06-15/generated/azure_mgmt_recovery_services_backup/models/protection_policy.rb', line 31

def protected_items_count
  @protected_items_count
end

Class Method Details

.mapperObject

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



38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
# File 'lib/2019-06-15/generated/azure_mgmt_recovery_services_backup/models/protection_policy.rb', line 38

def self.mapper()
  {
    client_side_validation: true,
    required: false,
    serialized_name: 'ProtectionPolicy',
    type: {
      name: 'Composite',
      polymorphic_discriminator: 'backupManagementType',
      uber_parent: 'ProtectionPolicy',
      class_name: 'ProtectionPolicy',
      model_properties: {
        protected_items_count: {
          client_side_validation: true,
          required: false,
          serialized_name: 'protectedItemsCount',
          type: {
            name: 'Number'
          }
        }
      }
    }
  }
end