Class: IntersightClient::HyperflexClusterBackupPolicyDeploymentAllOf
- Inherits:
-
Object
- Object
- IntersightClient::HyperflexClusterBackupPolicyDeploymentAllOf
- Defined in:
- lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb
Overview
Definition of the list of properties defined in ‘hyperflex.ClusterBackupPolicyDeployment’, excluding properties defined in parent classes.
Defined Under Namespace
Classes: EnumAttributeValidator
Instance Attribute Summary collapse
-
#backup_data_store_name ⇒ Object
Backup data store name used during the auto creation of the datastore.
-
#backup_data_store_size ⇒ Object
Replication data store size in backupDataStoreSizeUnit.
-
#backup_data_store_size_unit ⇒ Object
Replication data store size.
-
#backup_target ⇒ Object
Returns the value of attribute backup_target.
-
#class_id ⇒ Object
The fully-qualified name of the instantiated, concrete type.
-
#data_store_encryption_enabled ⇒ Object
Whether the datastore is encrypted or not.
-
#description ⇒ Object
Description from corresponding ClusterBackupPolicy.
-
#discovered ⇒ Object
True if record created by discovery on HyperFlex cluster.
-
#local_snapshot_retention_count ⇒ Object
Number of snapshots that will be retained as part of the Multi Point in Time support.
-
#name ⇒ Object
Name from corresponding ClusterBackupPolicy.
-
#object_type ⇒ Object
The fully-qualified name of the instantiated, concrete type.
-
#organization ⇒ Object
Returns the value of attribute organization.
-
#policy_moid ⇒ Object
Deployed cluster policy moid.
-
#profile_moid ⇒ Object
Deployed cluster profile moid.
-
#replication_pair_name_prefix ⇒ Object
Replication cluster pairing name prefix.
-
#replication_schedule ⇒ Object
Returns the value of attribute replication_schedule.
-
#snapshot_retention_count ⇒ Object
Number of snapshots that will be retained as part of the Multi Point in Time support.
-
#source_cluster ⇒ Object
Returns the value of attribute source_cluster.
-
#source_detached ⇒ Object
True if policy was detached from source Hyperflex Cluster.
-
#source_request_id ⇒ Object
Unique source cluster request ID allowing retry of the same logical request following a transient communication failure.
-
#source_uuid ⇒ Object
Uuid of the source Hyperflex Cluster.
-
#target_detached ⇒ Object
True if policy was detached from target Hyperflex Cluster.
-
#target_request_id ⇒ Object
Unique target cluster request ID allowing retry of the same logical request following a transient communication failure.
-
#target_uuid ⇒ Object
Uuid of the target Hyperflex Cluster.
Class Method Summary collapse
-
.acceptable_attribute_map ⇒ Object
Returns the key-value map of all the JSON attributes this model knows about.
-
.acceptable_attributes ⇒ Object
Returns all the JSON keys this model knows about.
-
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
-
.build_from_hash(attributes) ⇒ Object
Builds the object from hash.
-
.openapi_nullable ⇒ Object
List of attributes with nullable: true.
-
.openapi_types ⇒ Object
Attribute type mapping.
Instance Method Summary collapse
-
#==(o) ⇒ Object
Checks equality by comparing each attribute.
-
#_deserialize(type, value) ⇒ Object
Deserializes the data based on type.
-
#_to_hash(value) ⇒ Hash
Outputs non-array value in the form of hash For object, use to_hash.
-
#build_from_hash(attributes) ⇒ Object
Builds the object from hash.
- #eql?(o) ⇒ Boolean
-
#hash ⇒ Integer
Calculates hash code according to all attributes.
-
#initialize(attributes = {}) ⇒ HyperflexClusterBackupPolicyDeploymentAllOf
constructor
Initializes the object.
-
#list_invalid_properties ⇒ Object
Show invalid properties with the reasons.
-
#to_body ⇒ Hash
to_body is an alias to to_hash (backward compatibility).
-
#to_hash ⇒ Hash
Returns the object in the form of hash.
-
#to_s ⇒ String
Returns the string representation of the object.
-
#valid? ⇒ Boolean
Check to see if the all the properties in the model are valid.
Constructor Details
#initialize(attributes = {}) ⇒ HyperflexClusterBackupPolicyDeploymentAllOf
Initializes the object
188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 188 def initialize(attributes = {}) if (!attributes.is_a?(Hash)) fail ArgumentError, "The input argument (attributes) must be a hash in `IntersightClient::HyperflexClusterBackupPolicyDeploymentAllOf` initialize method" end # check to see if the attribute exists and convert string to symbol for hash key attributes = attributes.each_with_object({}) { |(k, v), h| if (!self.class.acceptable_attribute_map.key?(k.to_sym)) fail ArgumentError, "`#{k}` is not a valid attribute in `#{self.class.name}`. Please check the name to make sure it's valid. List of attributes: " + self.class.acceptable_attribute_map.keys.inspect end h[k.to_sym] = v } if attributes.key?(:'class_id') self.class_id = attributes[:'class_id'] else self.class_id = 'hyperflex.ClusterBackupPolicyDeployment' end if attributes.key?(:'object_type') self.object_type = attributes[:'object_type'] else self.object_type = 'hyperflex.ClusterBackupPolicyDeployment' end if attributes.key?(:'backup_data_store_name') self.backup_data_store_name = attributes[:'backup_data_store_name'] else self.backup_data_store_name = 'backup-source-ds' end if attributes.key?(:'backup_data_store_size') self.backup_data_store_size = attributes[:'backup_data_store_size'] else self.backup_data_store_size = 2 end if attributes.key?(:'backup_data_store_size_unit') self.backup_data_store_size_unit = attributes[:'backup_data_store_size_unit'] else self.backup_data_store_size_unit = 'TB' end if attributes.key?(:'data_store_encryption_enabled') self.data_store_encryption_enabled = attributes[:'data_store_encryption_enabled'] end if attributes.key?(:'description') self.description = attributes[:'description'] end if attributes.key?(:'discovered') self.discovered = attributes[:'discovered'] end if attributes.key?(:'local_snapshot_retention_count') self.local_snapshot_retention_count = attributes[:'local_snapshot_retention_count'] else self.local_snapshot_retention_count = 4 end if attributes.key?(:'name') self.name = attributes[:'name'] end if attributes.key?(:'policy_moid') self.policy_moid = attributes[:'policy_moid'] end if attributes.key?(:'profile_moid') self.profile_moid = attributes[:'profile_moid'] end if attributes.key?(:'replication_pair_name_prefix') self.replication_pair_name_prefix = attributes[:'replication_pair_name_prefix'] else self.replication_pair_name_prefix = 'backup' end if attributes.key?(:'replication_schedule') self.replication_schedule = attributes[:'replication_schedule'] end if attributes.key?(:'snapshot_retention_count') self.snapshot_retention_count = attributes[:'snapshot_retention_count'] else self.snapshot_retention_count = 4 end if attributes.key?(:'source_detached') self.source_detached = attributes[:'source_detached'] end if attributes.key?(:'source_request_id') self.source_request_id = attributes[:'source_request_id'] end if attributes.key?(:'source_uuid') self.source_uuid = attributes[:'source_uuid'] end if attributes.key?(:'target_detached') self.target_detached = attributes[:'target_detached'] end if attributes.key?(:'target_request_id') self.target_request_id = attributes[:'target_request_id'] end if attributes.key?(:'target_uuid') self.target_uuid = attributes[:'target_uuid'] end if attributes.key?(:'backup_target') self.backup_target = attributes[:'backup_target'] end if attributes.key?(:'organization') self.organization = attributes[:'organization'] end if attributes.key?(:'source_cluster') self.source_cluster = attributes[:'source_cluster'] end end |
Instance Attribute Details
#backup_data_store_name ⇒ Object
Backup data store name used during the auto creation of the datastore. All VMs created in this data store will be automatically backed up.
26 27 28 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 26 def backup_data_store_name @backup_data_store_name end |
#backup_data_store_size ⇒ Object
Replication data store size in backupDataStoreSizeUnit.
29 30 31 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 29 def backup_data_store_size @backup_data_store_size end |
#backup_data_store_size_unit ⇒ Object
Replication data store size.
32 33 34 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 32 def backup_data_store_size_unit @backup_data_store_size_unit end |
#backup_target ⇒ Object
Returns the value of attribute backup_target.
81 82 83 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 81 def backup_target @backup_target end |
#class_id ⇒ Object
The fully-qualified name of the instantiated, concrete type. This property is used as a discriminator to identify the type of the payload when marshaling and unmarshaling data.
20 21 22 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 20 def class_id @class_id end |
#data_store_encryption_enabled ⇒ Object
Whether the datastore is encrypted or not.
35 36 37 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 35 def data_store_encryption_enabled @data_store_encryption_enabled end |
#description ⇒ Object
Description from corresponding ClusterBackupPolicy.
38 39 40 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 38 def description @description end |
#discovered ⇒ Object
True if record created by discovery on HyperFlex cluster.
41 42 43 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 41 def discovered @discovered end |
#local_snapshot_retention_count ⇒ Object
Number of snapshots that will be retained as part of the Multi Point in Time support.
44 45 46 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 44 def local_snapshot_retention_count @local_snapshot_retention_count end |
#name ⇒ Object
Name from corresponding ClusterBackupPolicy.
47 48 49 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 47 def name @name end |
#object_type ⇒ Object
The fully-qualified name of the instantiated, concrete type. The value should be the same as the ‘ClassId’ property.
23 24 25 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 23 def object_type @object_type end |
#organization ⇒ Object
Returns the value of attribute organization.
83 84 85 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 83 def organization @organization end |
#policy_moid ⇒ Object
Deployed cluster policy moid.
50 51 52 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 50 def policy_moid @policy_moid end |
#profile_moid ⇒ Object
Deployed cluster profile moid.
53 54 55 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 53 def profile_moid @profile_moid end |
#replication_pair_name_prefix ⇒ Object
Replication cluster pairing name prefix.
56 57 58 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 56 def replication_pair_name_prefix @replication_pair_name_prefix end |
#replication_schedule ⇒ Object
Returns the value of attribute replication_schedule.
58 59 60 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 58 def replication_schedule @replication_schedule end |
#snapshot_retention_count ⇒ Object
Number of snapshots that will be retained as part of the Multi Point in Time support.
61 62 63 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 61 def snapshot_retention_count @snapshot_retention_count end |
#source_cluster ⇒ Object
Returns the value of attribute source_cluster.
85 86 87 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 85 def source_cluster @source_cluster end |
#source_detached ⇒ Object
True if policy was detached from source Hyperflex Cluster.
64 65 66 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 64 def source_detached @source_detached end |
#source_request_id ⇒ Object
Unique source cluster request ID allowing retry of the same logical request following a transient communication failure.
67 68 69 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 67 def source_request_id @source_request_id end |
#source_uuid ⇒ Object
Uuid of the source Hyperflex Cluster.
70 71 72 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 70 def source_uuid @source_uuid end |
#target_detached ⇒ Object
True if policy was detached from target Hyperflex Cluster.
73 74 75 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 73 def target_detached @target_detached end |
#target_request_id ⇒ Object
Unique target cluster request ID allowing retry of the same logical request following a transient communication failure.
76 77 78 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 76 def target_request_id @target_request_id end |
#target_uuid ⇒ Object
Uuid of the target Hyperflex Cluster.
79 80 81 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 79 def target_uuid @target_uuid end |
Class Method Details
.acceptable_attribute_map ⇒ Object
Returns the key-value map of all the JSON attributes this model knows about
145 146 147 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 145 def self.acceptable_attribute_map attribute_map end |
.acceptable_attributes ⇒ Object
Returns all the JSON keys this model knows about
140 141 142 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 140 def self.acceptable_attributes attribute_map.values end |
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 110 def self.attribute_map { :'class_id' => :'ClassId', :'object_type' => :'ObjectType', :'backup_data_store_name' => :'BackupDataStoreName', :'backup_data_store_size' => :'BackupDataStoreSize', :'backup_data_store_size_unit' => :'BackupDataStoreSizeUnit', :'data_store_encryption_enabled' => :'DataStoreEncryptionEnabled', :'description' => :'Description', :'discovered' => :'Discovered', :'local_snapshot_retention_count' => :'LocalSnapshotRetentionCount', :'name' => :'Name', :'policy_moid' => :'PolicyMoid', :'profile_moid' => :'ProfileMoid', :'replication_pair_name_prefix' => :'ReplicationPairNamePrefix', :'replication_schedule' => :'ReplicationSchedule', :'snapshot_retention_count' => :'SnapshotRetentionCount', :'source_detached' => :'SourceDetached', :'source_request_id' => :'SourceRequestId', :'source_uuid' => :'SourceUuid', :'target_detached' => :'TargetDetached', :'target_request_id' => :'TargetRequestId', :'target_uuid' => :'TargetUuid', :'backup_target' => :'BackupTarget', :'organization' => :'Organization', :'source_cluster' => :'SourceCluster' } end |
.build_from_hash(attributes) ⇒ Object
Builds the object from hash
455 456 457 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 455 def self.build_from_hash(attributes) new.build_from_hash(attributes) end |
.openapi_nullable ⇒ Object
List of attributes with nullable: true
180 181 182 183 184 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 180 def self.openapi_nullable Set.new([ :'replication_schedule', ]) end |
.openapi_types ⇒ Object
Attribute type mapping.
150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 150 def self.openapi_types { :'class_id' => :'String', :'object_type' => :'String', :'backup_data_store_name' => :'String', :'backup_data_store_size' => :'Integer', :'backup_data_store_size_unit' => :'String', :'data_store_encryption_enabled' => :'Boolean', :'description' => :'String', :'discovered' => :'Boolean', :'local_snapshot_retention_count' => :'Integer', :'name' => :'String', :'policy_moid' => :'String', :'profile_moid' => :'String', :'replication_pair_name_prefix' => :'String', :'replication_schedule' => :'HyperflexReplicationSchedule', :'snapshot_retention_count' => :'Integer', :'source_detached' => :'Boolean', :'source_request_id' => :'String', :'source_uuid' => :'String', :'target_detached' => :'Boolean', :'target_request_id' => :'String', :'target_uuid' => :'String', :'backup_target' => :'HyperflexClusterRelationship', :'organization' => :'OrganizationOrganizationRelationship', :'source_cluster' => :'HyperflexClusterRelationship' } end |
Instance Method Details
#==(o) ⇒ Object
Checks equality by comparing each attribute.
411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 411 def ==(o) return true if self.equal?(o) self.class == o.class && class_id == o.class_id && object_type == o.object_type && backup_data_store_name == o.backup_data_store_name && backup_data_store_size == o.backup_data_store_size && backup_data_store_size_unit == o.backup_data_store_size_unit && data_store_encryption_enabled == o.data_store_encryption_enabled && description == o.description && discovered == o.discovered && local_snapshot_retention_count == o.local_snapshot_retention_count && name == o.name && policy_moid == o.policy_moid && profile_moid == o.profile_moid && replication_pair_name_prefix == o.replication_pair_name_prefix && replication_schedule == o.replication_schedule && snapshot_retention_count == o.snapshot_retention_count && source_detached == o.source_detached && source_request_id == o.source_request_id && source_uuid == o.source_uuid && target_detached == o.target_detached && target_request_id == o.target_request_id && target_uuid == o.target_uuid && backup_target == o.backup_target && organization == o.organization && source_cluster == o.source_cluster end |
#_deserialize(type, value) ⇒ Object
Deserializes the data based on type
485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 485 def _deserialize(type, value) case type.to_sym when :Time Time.parse(value) when :Date Date.parse(value) when :String value.to_s when :Integer value.to_i when :Float value.to_f when :Boolean if value.to_s =~ /\A(true|t|yes|y|1)\z/i true else false end when :Object # generic object (usually a Hash), return directly value when /\AArray<(?<inner_type>.+)>\z/ inner_type = Regexp.last_match[:inner_type] value.map { |v| _deserialize(inner_type, v) } when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/ k_type = Regexp.last_match[:k_type] v_type = Regexp.last_match[:v_type] {}.tap do |hash| value.each do |k, v| hash[_deserialize(k_type, k)] = _deserialize(v_type, v) end end else # model # models (e.g. Pet) or oneOf klass = IntersightClient.const_get(type) klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end |
#_to_hash(value) ⇒ Hash
Outputs non-array value in the form of hash For object, use to_hash. Otherwise, just return the value
556 557 558 559 560 561 562 563 564 565 566 567 568 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 556 def _to_hash(value) if value.is_a?(Array) value.compact.map { |v| _to_hash(v) } elsif value.is_a?(Hash) {}.tap do |hash| value.each { |k, v| hash[k] = _to_hash(v) } end elsif value.respond_to? :to_hash value.to_hash else value end end |
#build_from_hash(attributes) ⇒ Object
Builds the object from hash
462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 462 def build_from_hash(attributes) return nil unless attributes.is_a?(Hash) HyperflexClusterBackupPolicyDeploymentAllOf.openapi_types.each_pair do |key, type| if attributes[HyperflexClusterBackupPolicyDeploymentAllOf.attribute_map[key]].nil? && HyperflexClusterBackupPolicyDeploymentAllOf.openapi_nullable.include?(key) self.send("#{key}=", nil) elsif type =~ /\AArray<(.*)>/i # check to ensure the input is an array given that the attribute # is documented as an array but the input is not if attributes[HyperflexClusterBackupPolicyDeploymentAllOf.attribute_map[key]].is_a?(Array) self.send("#{key}=", attributes[HyperflexClusterBackupPolicyDeploymentAllOf.attribute_map[key]].map { |v| _deserialize($1, v) }) end elsif !attributes[HyperflexClusterBackupPolicyDeploymentAllOf.attribute_map[key]].nil? self.send("#{key}=", _deserialize(type, attributes[HyperflexClusterBackupPolicyDeploymentAllOf.attribute_map[key]])) end end self end |
#eql?(o) ⇒ Boolean
442 443 444 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 442 def eql?(o) self == o end |
#hash ⇒ Integer
Calculates hash code according to all attributes.
448 449 450 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 448 def hash [class_id, object_type, backup_data_store_name, backup_data_store_size, backup_data_store_size_unit, data_store_encryption_enabled, description, discovered, local_snapshot_retention_count, name, policy_moid, profile_moid, replication_pair_name_prefix, replication_schedule, snapshot_retention_count, source_detached, source_request_id, source_uuid, target_detached, target_request_id, target_uuid, backup_target, organization, source_cluster].hash end |
#list_invalid_properties ⇒ Object
Show invalid properties with the reasons. Usually used together with valid?
316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 316 def list_invalid_properties invalid_properties = Array.new if @class_id.nil? invalid_properties.push('invalid value for "class_id", class_id cannot be nil.') end if @object_type.nil? invalid_properties.push('invalid value for "object_type", object_type cannot be nil.') end if !@local_snapshot_retention_count.nil? && @local_snapshot_retention_count > 30 invalid_properties.push('invalid value for "local_snapshot_retention_count", must be smaller than or equal to 30.') end if !@local_snapshot_retention_count.nil? && @local_snapshot_retention_count < 1 invalid_properties.push('invalid value for "local_snapshot_retention_count", must be greater than or equal to 1.') end if !@snapshot_retention_count.nil? && @snapshot_retention_count > 30 invalid_properties.push('invalid value for "snapshot_retention_count", must be smaller than or equal to 30.') end if !@snapshot_retention_count.nil? && @snapshot_retention_count < 1 invalid_properties.push('invalid value for "snapshot_retention_count", must be greater than or equal to 1.') end invalid_properties end |
#to_body ⇒ Hash
to_body is an alias to to_hash (backward compatibility)
532 533 534 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 532 def to_body to_hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
538 539 540 541 542 543 544 545 546 547 548 549 550 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 538 def to_hash hash = {} HyperflexClusterBackupPolicyDeploymentAllOf.attribute_map.each_pair do |attr, param| value = self.send(attr) if value.nil? is_nullable = HyperflexClusterBackupPolicyDeploymentAllOf.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end hash[param] = _to_hash(value) end hash end |
#to_s ⇒ String
Returns the string representation of the object
526 527 528 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 526 def to_s to_hash.to_s end |
#valid? ⇒ Boolean
Check to see if the all the properties in the model are valid
347 348 349 350 351 352 353 354 355 356 357 358 359 |
# File 'lib/intersight_client/models/hyperflex_cluster_backup_policy_deployment_all_of.rb', line 347 def valid? return false if @class_id.nil? class_id_validator = EnumAttributeValidator.new('String', ["hyperflex.ClusterBackupPolicyDeployment"]) return false unless class_id_validator.valid?(@class_id) return false if @object_type.nil? object_type_validator = EnumAttributeValidator.new('String', ["hyperflex.ClusterBackupPolicyDeployment"]) return false unless object_type_validator.valid?(@object_type) return false if !@local_snapshot_retention_count.nil? && @local_snapshot_retention_count > 30 return false if !@local_snapshot_retention_count.nil? && @local_snapshot_retention_count < 1 return false if !@snapshot_retention_count.nil? && @snapshot_retention_count > 30 return false if !@snapshot_retention_count.nil? && @snapshot_retention_count < 1 true end |