Class: OCI::DatabaseManagement::Models::ExternalAsmInstanceParameters
- Inherits:
-
Object
- Object
- OCI::DatabaseManagement::Models::ExternalAsmInstanceParameters
- Defined in:
- lib/oci/database_management/models/external_asm_instance_parameters.rb
Overview
The initialization parameters for an ASM instance.
Instance Attribute Summary collapse
-
#asm_instance_display_name ⇒ String
[Required] The user-friendly name for the ASM instance.
-
#asm_instance_id ⇒ String
[Required] The OCID of the external ASM instance.
-
#auto_mount_disk_groups ⇒ Array<String>
[Required] The list of disk group names that an ASM instance mounts at startup or when the
ALTER DISKGROUP ALL MOUNT
statement is issued. -
#disk_discovery_path ⇒ String
[Required] An operating system-dependent value used to limit the set of disks considered for discovery.
-
#preferred_read_failure_groups ⇒ Array<String>
[Required] The list of failure groups that contain preferred read disks.
-
#rebalance_power ⇒ Integer
[Required] The maximum power on an ASM instance for disk rebalancing.
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 = {}) ⇒ ExternalAsmInstanceParameters
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 = {}) ⇒ ExternalAsmInstanceParameters
Initializes the object
78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 |
# File 'lib/oci/database_management/models/external_asm_instance_parameters.rb', line 78 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.asm_instance_id = attributes[:'asmInstanceId'] if attributes[:'asmInstanceId'] raise 'You cannot provide both :asmInstanceId and :asm_instance_id' if attributes.key?(:'asmInstanceId') && attributes.key?(:'asm_instance_id') self.asm_instance_id = attributes[:'asm_instance_id'] if attributes[:'asm_instance_id'] self.asm_instance_display_name = attributes[:'asmInstanceDisplayName'] if attributes[:'asmInstanceDisplayName'] raise 'You cannot provide both :asmInstanceDisplayName and :asm_instance_display_name' if attributes.key?(:'asmInstanceDisplayName') && attributes.key?(:'asm_instance_display_name') self.asm_instance_display_name = attributes[:'asm_instance_display_name'] if attributes[:'asm_instance_display_name'] self.disk_discovery_path = attributes[:'diskDiscoveryPath'] if attributes[:'diskDiscoveryPath'] raise 'You cannot provide both :diskDiscoveryPath and :disk_discovery_path' if attributes.key?(:'diskDiscoveryPath') && attributes.key?(:'disk_discovery_path') self.disk_discovery_path = attributes[:'disk_discovery_path'] if attributes[:'disk_discovery_path'] self.auto_mount_disk_groups = attributes[:'autoMountDiskGroups'] if attributes[:'autoMountDiskGroups'] raise 'You cannot provide both :autoMountDiskGroups and :auto_mount_disk_groups' if attributes.key?(:'autoMountDiskGroups') && attributes.key?(:'auto_mount_disk_groups') self.auto_mount_disk_groups = attributes[:'auto_mount_disk_groups'] if attributes[:'auto_mount_disk_groups'] self.rebalance_power = attributes[:'rebalancePower'] if attributes[:'rebalancePower'] raise 'You cannot provide both :rebalancePower and :rebalance_power' if attributes.key?(:'rebalancePower') && attributes.key?(:'rebalance_power') self.rebalance_power = attributes[:'rebalance_power'] if attributes[:'rebalance_power'] self.preferred_read_failure_groups = attributes[:'preferredReadFailureGroups'] if attributes[:'preferredReadFailureGroups'] raise 'You cannot provide both :preferredReadFailureGroups and :preferred_read_failure_groups' if attributes.key?(:'preferredReadFailureGroups') && attributes.key?(:'preferred_read_failure_groups') self.preferred_read_failure_groups = attributes[:'preferred_read_failure_groups'] if attributes[:'preferred_read_failure_groups'] end |
Instance Attribute Details
#asm_instance_display_name ⇒ String
[Required] The user-friendly name for the ASM instance. The name does not have to be unique.
17 18 19 |
# File 'lib/oci/database_management/models/external_asm_instance_parameters.rb', line 17 def asm_instance_display_name @asm_instance_display_name end |
#asm_instance_id ⇒ String
[Required] The OCID of the external ASM instance.
13 14 15 |
# File 'lib/oci/database_management/models/external_asm_instance_parameters.rb', line 13 def asm_instance_id @asm_instance_id end |
#auto_mount_disk_groups ⇒ Array<String>
[Required] The list of disk group names that an ASM instance mounts at startup or when the ALTER DISKGROUP ALL MOUNT
statement is issued.
27 28 29 |
# File 'lib/oci/database_management/models/external_asm_instance_parameters.rb', line 27 def auto_mount_disk_groups @auto_mount_disk_groups end |
#disk_discovery_path ⇒ String
[Required] An operating system-dependent value used to limit the set of disks considered for discovery.
22 23 24 |
# File 'lib/oci/database_management/models/external_asm_instance_parameters.rb', line 22 def disk_discovery_path @disk_discovery_path end |
#preferred_read_failure_groups ⇒ Array<String>
[Required] The list of failure groups that contain preferred read disks.
36 37 38 |
# File 'lib/oci/database_management/models/external_asm_instance_parameters.rb', line 36 def preferred_read_failure_groups @preferred_read_failure_groups end |
#rebalance_power ⇒ Integer
[Required] The maximum power on an ASM instance for disk rebalancing.
32 33 34 |
# File 'lib/oci/database_management/models/external_asm_instance_parameters.rb', line 32 def rebalance_power @rebalance_power end |
Class Method Details
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
39 40 41 42 43 44 45 46 47 48 49 50 |
# File 'lib/oci/database_management/models/external_asm_instance_parameters.rb', line 39 def self.attribute_map { # rubocop:disable Style/SymbolLiteral 'asm_instance_id': :'asmInstanceId', 'asm_instance_display_name': :'asmInstanceDisplayName', 'disk_discovery_path': :'diskDiscoveryPath', 'auto_mount_disk_groups': :'autoMountDiskGroups', 'rebalance_power': :'rebalancePower', 'preferred_read_failure_groups': :'preferredReadFailureGroups' # rubocop:enable Style/SymbolLiteral } end |
.swagger_types ⇒ Object
Attribute type mapping.
53 54 55 56 57 58 59 60 61 62 63 64 |
# File 'lib/oci/database_management/models/external_asm_instance_parameters.rb', line 53 def self.swagger_types { # rubocop:disable Style/SymbolLiteral 'asm_instance_id': :'String', 'asm_instance_display_name': :'String', 'disk_discovery_path': :'String', 'auto_mount_disk_groups': :'Array<String>', 'rebalance_power': :'Integer', 'preferred_read_failure_groups': :'Array<String>' # rubocop:enable Style/SymbolLiteral } end |
Instance Method Details
#==(other) ⇒ Object
Checks equality by comparing each attribute.
128 129 130 131 132 133 134 135 136 137 138 |
# File 'lib/oci/database_management/models/external_asm_instance_parameters.rb', line 128 def ==(other) return true if equal?(other) self.class == other.class && asm_instance_id == other.asm_instance_id && asm_instance_display_name == other.asm_instance_display_name && disk_discovery_path == other.disk_discovery_path && auto_mount_disk_groups == other.auto_mount_disk_groups && rebalance_power == other.rebalance_power && preferred_read_failure_groups == other.preferred_read_failure_groups end |
#build_from_hash(attributes) ⇒ Object
Builds the object from hash
163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 |
# File 'lib/oci/database_management/models/external_asm_instance_parameters.rb', line 163 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
143 144 145 |
# File 'lib/oci/database_management/models/external_asm_instance_parameters.rb', line 143 def eql?(other) self == other end |
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
152 153 154 |
# File 'lib/oci/database_management/models/external_asm_instance_parameters.rb', line 152 def hash [asm_instance_id, asm_instance_display_name, disk_discovery_path, auto_mount_disk_groups, rebalance_power, preferred_read_failure_groups].hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
196 197 198 199 200 201 202 203 204 205 |
# File 'lib/oci/database_management/models/external_asm_instance_parameters.rb', line 196 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
190 191 192 |
# File 'lib/oci/database_management/models/external_asm_instance_parameters.rb', line 190 def to_s to_hash.to_s end |