Class: OCI::DatabaseManagement::Models::ExternalExadataStorageGridSummary
- Inherits:
-
DbmResource
- Object
- DbmResource
- OCI::DatabaseManagement::Models::ExternalExadataStorageGridSummary
- Defined in:
- lib/oci/database_management/models/external_exadata_storage_grid_summary.rb
Overview
The Exadata storage server grid of the Exadata infrastructure.
Constant Summary
Constants inherited from DbmResource
DbmResource::LIFECYCLE_STATE_ENUM, DbmResource::RESOURCE_TYPE_ENUM
Instance Attribute Summary collapse
-
#server_count ⇒ Float
The number of Exadata storage servers in the Exadata infrastructure.
Attributes inherited from DbmResource
#additional_details, #display_name, #id, #internal_id, #lifecycle_details, #lifecycle_state, #resource_type, #status, #time_created, #time_updated, #version
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 = {}) ⇒ ExternalExadataStorageGridSummary
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.
Methods inherited from DbmResource
Constructor Details
#initialize(attributes = {}) ⇒ ExternalExadataStorageGridSummary
Initializes the object
73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 |
# File 'lib/oci/database_management/models/external_exadata_storage_grid_summary.rb', line 73 def initialize(attributes = {}) return unless attributes.is_a?(Hash) attributes['resourceType'] = 'STORAGE_GRID_SUMMARY' super(attributes) # convert string to symbol for hash key attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v } self.server_count = attributes[:'serverCount'] if attributes[:'serverCount'] raise 'You cannot provide both :serverCount and :server_count' if attributes.key?(:'serverCount') && attributes.key?(:'server_count') self.server_count = attributes[:'server_count'] if attributes[:'server_count'] end |
Instance Attribute Details
#server_count ⇒ Float
The number of Exadata storage servers in the Exadata infrastructure.
14 15 16 |
# File 'lib/oci/database_management/models/external_exadata_storage_grid_summary.rb', line 14 def server_count @server_count end |
Class Method Details
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 |
# File 'lib/oci/database_management/models/external_exadata_storage_grid_summary.rb', line 17 def self.attribute_map { # rubocop:disable Style/SymbolLiteral 'id': :'id', 'display_name': :'displayName', 'version': :'version', 'internal_id': :'internalId', 'status': :'status', 'lifecycle_state': :'lifecycleState', 'time_created': :'timeCreated', 'time_updated': :'timeUpdated', 'lifecycle_details': :'lifecycleDetails', 'additional_details': :'additionalDetails', 'resource_type': :'resourceType', 'server_count': :'serverCount' # rubocop:enable Style/SymbolLiteral } end |
.swagger_types ⇒ Object
Attribute type mapping.
37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 |
# File 'lib/oci/database_management/models/external_exadata_storage_grid_summary.rb', line 37 def self.swagger_types { # rubocop:disable Style/SymbolLiteral 'id': :'String', 'display_name': :'String', 'version': :'String', 'internal_id': :'String', 'status': :'String', 'lifecycle_state': :'String', 'time_created': :'DateTime', 'time_updated': :'DateTime', 'lifecycle_details': :'String', 'additional_details': :'Hash<String, String>', 'resource_type': :'String', 'server_count': :'Float' # rubocop:enable Style/SymbolLiteral } end |
Instance Method Details
#==(other) ⇒ Object
Checks equality by comparing each attribute.
97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 |
# File 'lib/oci/database_management/models/external_exadata_storage_grid_summary.rb', line 97 def ==(other) return true if equal?(other) self.class == other.class && id == other.id && display_name == other.display_name && version == other.version && internal_id == other.internal_id && status == other.status && lifecycle_state == other.lifecycle_state && time_created == other.time_created && time_updated == other.time_updated && lifecycle_details == other.lifecycle_details && additional_details == other.additional_details && resource_type == other.resource_type && server_count == other.server_count end |
#build_from_hash(attributes) ⇒ Object
Builds the object from hash
138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 |
# File 'lib/oci/database_management/models/external_exadata_storage_grid_summary.rb', line 138 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
118 119 120 |
# File 'lib/oci/database_management/models/external_exadata_storage_grid_summary.rb', line 118 def eql?(other) self == other end |
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
127 128 129 |
# File 'lib/oci/database_management/models/external_exadata_storage_grid_summary.rb', line 127 def hash [id, display_name, version, internal_id, status, lifecycle_state, time_created, time_updated, lifecycle_details, additional_details, resource_type, server_count].hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
171 172 173 174 175 176 177 178 179 180 |
# File 'lib/oci/database_management/models/external_exadata_storage_grid_summary.rb', line 171 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
165 166 167 |
# File 'lib/oci/database_management/models/external_exadata_storage_grid_summary.rb', line 165 def to_s to_hash.to_s end |