Class: Azure::RecoveryServicesBackup::Mgmt::V2017_07_01::Models::ProtectionPolicy

Inherits:
Object
  • Object
show all
Includes:
MsRestAzure
Defined in:
lib/2017-07-01/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.



28
29
30
# File 'lib/2017-07-01/generated/azure_mgmt_recovery_services_backup/models/protection_policy.rb', line 28

def initialize
  @backupManagementType = "ProtectionPolicy"
end

Instance Attribute Details

#backupManagementTypeObject

Returns the value of attribute backupManagementType.



32
33
34
# File 'lib/2017-07-01/generated/azure_mgmt_recovery_services_backup/models/protection_policy.rb', line 32

def backupManagementType
  @backupManagementType
end

#protected_items_countInteger

Returns Number of items associated with this policy.

Returns:

  • (Integer)

    Number of items associated with this policy.



35
36
37
# File 'lib/2017-07-01/generated/azure_mgmt_recovery_services_backup/models/protection_policy.rb', line 35

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.



42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
# File 'lib/2017-07-01/generated/azure_mgmt_recovery_services_backup/models/protection_policy.rb', line 42

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