Class: OCI::DatabaseManagement::Models::ExternalAsmDiskGroupSummary
- Inherits:
-
Object
- Object
- OCI::DatabaseManagement::Models::ExternalAsmDiskGroupSummary
- Defined in:
- lib/oci/database_management/models/external_asm_disk_group_summary.rb
Overview
The summary of an external ASM disk group.
Constant Summary collapse
- REDUNDANCY_TYPE_ENUM =
[ REDUNDANCY_TYPE_EXTEND = 'EXTEND'.freeze, REDUNDANCY_TYPE_EXTERN = 'EXTERN'.freeze, REDUNDANCY_TYPE_FLEX = 'FLEX'.freeze, REDUNDANCY_TYPE_HIGH = 'HIGH'.freeze, REDUNDANCY_TYPE_NORMAL = 'NORMAL'.freeze, REDUNDANCY_TYPE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze ].freeze
Instance Attribute Summary collapse
-
#databases ⇒ Array<String>
The unique names of the databases using the disk group.
-
#dismounting_instance_count ⇒ Integer
The number of ASM instances that have the disk group in dismounted state.
-
#is_sparse ⇒ BOOLEAN
Indicates whether the disk group is a sparse disk group or not.
-
#mounting_instance_count ⇒ Integer
The number of ASM instances that have the disk group in mounted state.
-
#name ⇒ String
[Required] The name of the ASM disk group.
-
#redundancy_type ⇒ String
The redundancy type of the disk group.
-
#total_size_in_mbs ⇒ Integer
The total capacity of the disk group (in megabytes).
-
#used_percent ⇒ Float
The percentage of used space in the disk group.
-
#used_size_in_mbs ⇒ Integer
The used capacity of the disk group (in megabytes).
Class Method Summary collapse
-
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
-
.swagger_types ⇒ Object
Attribute type mapping.
Instance Method Summary collapse
-
#==(other) ⇒ Object
Checks equality by comparing each attribute.
-
#build_from_hash(attributes) ⇒ Object
Builds the object from hash.
- #eql?(other) ⇒ Boolean
-
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
-
#initialize(attributes = {}) ⇒ ExternalAsmDiskGroupSummary
constructor
Initializes the object.
-
#to_hash ⇒ Hash
Returns the object in the form of hash.
-
#to_s ⇒ String
Returns the string representation of the object.
Constructor Details
#initialize(attributes = {}) ⇒ ExternalAsmDiskGroupSummary
Initializes the object
106 107 108 109 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 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 |
# File 'lib/oci/database_management/models/external_asm_disk_group_summary.rb', line 106 def initialize(attributes = {}) return unless attributes.is_a?(Hash) # convert string to symbol for hash key attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v } self.name = attributes[:'name'] if attributes[:'name'] self.mounting_instance_count = attributes[:'mountingInstanceCount'] if attributes[:'mountingInstanceCount'] raise 'You cannot provide both :mountingInstanceCount and :mounting_instance_count' if attributes.key?(:'mountingInstanceCount') && attributes.key?(:'mounting_instance_count') self.mounting_instance_count = attributes[:'mounting_instance_count'] if attributes[:'mounting_instance_count'] self.dismounting_instance_count = attributes[:'dismountingInstanceCount'] if attributes[:'dismountingInstanceCount'] raise 'You cannot provide both :dismountingInstanceCount and :dismounting_instance_count' if attributes.key?(:'dismountingInstanceCount') && attributes.key?(:'dismounting_instance_count') self.dismounting_instance_count = attributes[:'dismounting_instance_count'] if attributes[:'dismounting_instance_count'] self.redundancy_type = attributes[:'redundancyType'] if attributes[:'redundancyType'] raise 'You cannot provide both :redundancyType and :redundancy_type' if attributes.key?(:'redundancyType') && attributes.key?(:'redundancy_type') self.redundancy_type = attributes[:'redundancy_type'] if attributes[:'redundancy_type'] self.is_sparse = attributes[:'isSparse'] unless attributes[:'isSparse'].nil? raise 'You cannot provide both :isSparse and :is_sparse' if attributes.key?(:'isSparse') && attributes.key?(:'is_sparse') self.is_sparse = attributes[:'is_sparse'] unless attributes[:'is_sparse'].nil? self.databases = attributes[:'databases'] if attributes[:'databases'] self.total_size_in_mbs = attributes[:'totalSizeInMBs'] if attributes[:'totalSizeInMBs'] raise 'You cannot provide both :totalSizeInMBs and :total_size_in_mbs' if attributes.key?(:'totalSizeInMBs') && attributes.key?(:'total_size_in_mbs') self.total_size_in_mbs = attributes[:'total_size_in_mbs'] if attributes[:'total_size_in_mbs'] self.used_size_in_mbs = attributes[:'usedSizeInMBs'] if attributes[:'usedSizeInMBs'] raise 'You cannot provide both :usedSizeInMBs and :used_size_in_mbs' if attributes.key?(:'usedSizeInMBs') && attributes.key?(:'used_size_in_mbs') self.used_size_in_mbs = attributes[:'used_size_in_mbs'] if attributes[:'used_size_in_mbs'] self.used_percent = attributes[:'usedPercent'] if attributes[:'usedPercent'] raise 'You cannot provide both :usedPercent and :used_percent' if attributes.key?(:'usedPercent') && attributes.key?(:'used_percent') self.used_percent = attributes[:'used_percent'] if attributes[:'used_percent'] end |
Instance Attribute Details
#databases ⇒ Array<String>
The unique names of the databases using the disk group.
43 44 45 |
# File 'lib/oci/database_management/models/external_asm_disk_group_summary.rb', line 43 def databases @databases end |
#dismounting_instance_count ⇒ Integer
The number of ASM instances that have the disk group in dismounted state.
31 32 33 |
# File 'lib/oci/database_management/models/external_asm_disk_group_summary.rb', line 31 def dismounting_instance_count @dismounting_instance_count end |
#is_sparse ⇒ BOOLEAN
Indicates whether the disk group is a sparse disk group or not.
39 40 41 |
# File 'lib/oci/database_management/models/external_asm_disk_group_summary.rb', line 39 def is_sparse @is_sparse end |
#mounting_instance_count ⇒ Integer
The number of ASM instances that have the disk group in mounted state.
27 28 29 |
# File 'lib/oci/database_management/models/external_asm_disk_group_summary.rb', line 27 def mounting_instance_count @mounting_instance_count end |
#name ⇒ String
[Required] The name of the ASM disk group.
23 24 25 |
# File 'lib/oci/database_management/models/external_asm_disk_group_summary.rb', line 23 def name @name end |
#redundancy_type ⇒ String
The redundancy type of the disk group.
35 36 37 |
# File 'lib/oci/database_management/models/external_asm_disk_group_summary.rb', line 35 def redundancy_type @redundancy_type end |
#total_size_in_mbs ⇒ Integer
The total capacity of the disk group (in megabytes).
47 48 49 |
# File 'lib/oci/database_management/models/external_asm_disk_group_summary.rb', line 47 def total_size_in_mbs @total_size_in_mbs end |
#used_percent ⇒ Float
The percentage of used space in the disk group.
55 56 57 |
# File 'lib/oci/database_management/models/external_asm_disk_group_summary.rb', line 55 def used_percent @used_percent end |
#used_size_in_mbs ⇒ Integer
The used capacity of the disk group (in megabytes).
51 52 53 |
# File 'lib/oci/database_management/models/external_asm_disk_group_summary.rb', line 51 def used_size_in_mbs @used_size_in_mbs end |
Class Method Details
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 |
# File 'lib/oci/database_management/models/external_asm_disk_group_summary.rb', line 58 def self.attribute_map { # rubocop:disable Style/SymbolLiteral 'name': :'name', 'mounting_instance_count': :'mountingInstanceCount', 'dismounting_instance_count': :'dismountingInstanceCount', 'redundancy_type': :'redundancyType', 'is_sparse': :'isSparse', 'databases': :'databases', 'total_size_in_mbs': :'totalSizeInMBs', 'used_size_in_mbs': :'usedSizeInMBs', 'used_percent': :'usedPercent' # rubocop:enable Style/SymbolLiteral } end |
.swagger_types ⇒ Object
Attribute type mapping.
75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 |
# File 'lib/oci/database_management/models/external_asm_disk_group_summary.rb', line 75 def self.swagger_types { # rubocop:disable Style/SymbolLiteral 'name': :'String', 'mounting_instance_count': :'Integer', 'dismounting_instance_count': :'Integer', 'redundancy_type': :'String', 'is_sparse': :'BOOLEAN', 'databases': :'Array<String>', 'total_size_in_mbs': :'Integer', 'used_size_in_mbs': :'Integer', 'used_percent': :'Float' # rubocop:enable Style/SymbolLiteral } end |
Instance Method Details
#==(other) ⇒ Object
Checks equality by comparing each attribute.
179 180 181 182 183 184 185 186 187 188 189 190 191 192 |
# File 'lib/oci/database_management/models/external_asm_disk_group_summary.rb', line 179 def ==(other) return true if equal?(other) self.class == other.class && name == other.name && mounting_instance_count == other.mounting_instance_count && dismounting_instance_count == other.dismounting_instance_count && redundancy_type == other.redundancy_type && is_sparse == other.is_sparse && databases == other.databases && total_size_in_mbs == other.total_size_in_mbs && used_size_in_mbs == other.used_size_in_mbs && used_percent == other.used_percent end |
#build_from_hash(attributes) ⇒ Object
Builds the object from hash
217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 |
# File 'lib/oci/database_management/models/external_asm_disk_group_summary.rb', line 217 def build_from_hash(attributes) return nil unless attributes.is_a?(Hash) self.class.swagger_types.each_pair do |key, type| if type =~ /^Array<(.*)>/i # check to ensure the input is an array given that the the attribute # is documented as an array but the input is not if attributes[self.class.attribute_map[key]].is_a?(Array) public_method("#{key}=").call( attributes[self.class.attribute_map[key]] .map { |v| OCI::Internal::Util.convert_to_type(Regexp.last_match(1), v) } ) end elsif !attributes[self.class.attribute_map[key]].nil? public_method("#{key}=").call( OCI::Internal::Util.convert_to_type(type, attributes[self.class.attribute_map[key]]) ) end # or else data not found in attributes(hash), not an issue as the data can be optional end self end |
#eql?(other) ⇒ Boolean
197 198 199 |
# File 'lib/oci/database_management/models/external_asm_disk_group_summary.rb', line 197 def eql?(other) self == other end |
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
206 207 208 |
# File 'lib/oci/database_management/models/external_asm_disk_group_summary.rb', line 206 def hash [name, mounting_instance_count, dismounting_instance_count, redundancy_type, is_sparse, databases, total_size_in_mbs, used_size_in_mbs, used_percent].hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
250 251 252 253 254 255 256 257 258 259 |
# File 'lib/oci/database_management/models/external_asm_disk_group_summary.rb', line 250 def to_hash hash = {} self.class.attribute_map.each_pair do |attr, param| value = public_method(attr).call next if value.nil? && !instance_variable_defined?("@#{attr}") hash[param] = _to_hash(value) end hash end |
#to_s ⇒ String
Returns the string representation of the object
244 245 246 |
# File 'lib/oci/database_management/models/external_asm_disk_group_summary.rb', line 244 def to_s to_hash.to_s end |