Class: OCI::Multicloud::Models::ExternalLocationsMetadatumSummary
- Inherits:
-
Object
- Object
- OCI::Multicloud::Models::ExternalLocationsMetadatumSummary
- Defined in:
- lib/oci/multicloud/models/external_locations_metadatum_summary.rb
Overview
Flat Map of CSP Region -> CSP-Physical-AZ -> CSP-Logical-AZ -> OCI Site Group -> CPG-ID
Instance Attribute Summary collapse
-
#cluster_placement_group_id ⇒ String
[Required] Cluster Placement Group OCID.
-
#cpg_id ⇒ String
[Required] Cluster Placement Group OCID (deprecated representation).
-
#defined_tags ⇒ Hash<String, Hash<String, Object>>
[Required] Defined tags for this resource.
-
#external_location ⇒ OCI::Multicloud::Models::ExternalLocationDetail
This attribute is required.
-
#freeform_tags ⇒ Hash<String, String>
[Required] Free-form tags for this resource.
-
#oci_logical_ad ⇒ String
OCI logical ad name.
-
#oci_physical_ad ⇒ String
[Required] OCI physical ad name.
-
#oci_region ⇒ String
[Required] OCI region identifier docs.oracle.com/en-us/iaas/Content/General/Concepts/regions.htm.
-
#partner_cloud_account_name ⇒ String
User friendly name of account name for customer's subscription.
-
#partner_cloud_account_url ⇒ String
Direct URL to partner cloud for customer's account.
-
#partner_cloud_name ⇒ String
Partner Cloud Name based on service name.
-
#system_tags ⇒ Hash<String, Hash<String, Object>>
System tags for this resource.
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 = {}) ⇒ ExternalLocationsMetadatumSummary
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 = {}) ⇒ ExternalLocationsMetadatumSummary
Initializes the object
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 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 |
# File 'lib/oci/multicloud/models/external_locations_metadatum_summary.rb', line 128 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. = attributes[:'freeformTags'] if attributes[:'freeformTags'] raise 'You cannot provide both :freeformTags and :freeform_tags' if attributes.key?(:'freeformTags') && attributes.key?(:'freeform_tags') self. = attributes[:'freeform_tags'] if attributes[:'freeform_tags'] self. = attributes[:'definedTags'] if attributes[:'definedTags'] raise 'You cannot provide both :definedTags and :defined_tags' if attributes.key?(:'definedTags') && attributes.key?(:'defined_tags') self. = attributes[:'defined_tags'] if attributes[:'defined_tags'] self. = attributes[:'systemTags'] if attributes[:'systemTags'] raise 'You cannot provide both :systemTags and :system_tags' if attributes.key?(:'systemTags') && attributes.key?(:'system_tags') self. = attributes[:'system_tags'] if attributes[:'system_tags'] self.external_location = attributes[:'externalLocation'] if attributes[:'externalLocation'] raise 'You cannot provide both :externalLocation and :external_location' if attributes.key?(:'externalLocation') && attributes.key?(:'external_location') self.external_location = attributes[:'external_location'] if attributes[:'external_location'] self.oci_physical_ad = attributes[:'ociPhysicalAd'] if attributes[:'ociPhysicalAd'] raise 'You cannot provide both :ociPhysicalAd and :oci_physical_ad' if attributes.key?(:'ociPhysicalAd') && attributes.key?(:'oci_physical_ad') self.oci_physical_ad = attributes[:'oci_physical_ad'] if attributes[:'oci_physical_ad'] self.oci_logical_ad = attributes[:'ociLogicalAd'] if attributes[:'ociLogicalAd'] raise 'You cannot provide both :ociLogicalAd and :oci_logical_ad' if attributes.key?(:'ociLogicalAd') && attributes.key?(:'oci_logical_ad') self.oci_logical_ad = attributes[:'oci_logical_ad'] if attributes[:'oci_logical_ad'] self.oci_region = attributes[:'ociRegion'] if attributes[:'ociRegion'] raise 'You cannot provide both :ociRegion and :oci_region' if attributes.key?(:'ociRegion') && attributes.key?(:'oci_region') self.oci_region = attributes[:'oci_region'] if attributes[:'oci_region'] self.cpg_id = attributes[:'cpgId'] if attributes[:'cpgId'] raise 'You cannot provide both :cpgId and :cpg_id' if attributes.key?(:'cpgId') && attributes.key?(:'cpg_id') self.cpg_id = attributes[:'cpg_id'] if attributes[:'cpg_id'] self.cluster_placement_group_id = attributes[:'clusterPlacementGroupId'] if attributes[:'clusterPlacementGroupId'] raise 'You cannot provide both :clusterPlacementGroupId and :cluster_placement_group_id' if attributes.key?(:'clusterPlacementGroupId') && attributes.key?(:'cluster_placement_group_id') self.cluster_placement_group_id = attributes[:'cluster_placement_group_id'] if attributes[:'cluster_placement_group_id'] self.partner_cloud_name = attributes[:'partnerCloudName'] if attributes[:'partnerCloudName'] raise 'You cannot provide both :partnerCloudName and :partner_cloud_name' if attributes.key?(:'partnerCloudName') && attributes.key?(:'partner_cloud_name') self.partner_cloud_name = attributes[:'partner_cloud_name'] if attributes[:'partner_cloud_name'] self.partner_cloud_account_name = attributes[:'partnerCloudAccountName'] if attributes[:'partnerCloudAccountName'] raise 'You cannot provide both :partnerCloudAccountName and :partner_cloud_account_name' if attributes.key?(:'partnerCloudAccountName') && attributes.key?(:'partner_cloud_account_name') self.partner_cloud_account_name = attributes[:'partner_cloud_account_name'] if attributes[:'partner_cloud_account_name'] self.partner_cloud_account_url = attributes[:'partnerCloudAccountUrl'] if attributes[:'partnerCloudAccountUrl'] raise 'You cannot provide both :partnerCloudAccountUrl and :partner_cloud_account_url' if attributes.key?(:'partnerCloudAccountUrl') && attributes.key?(:'partner_cloud_account_url') self.partner_cloud_account_url = attributes[:'partner_cloud_account_url'] if attributes[:'partner_cloud_account_url'] end |
Instance Attribute Details
#cluster_placement_group_id ⇒ String
[Required] Cluster Placement Group OCID
56 57 58 |
# File 'lib/oci/multicloud/models/external_locations_metadatum_summary.rb', line 56 def cluster_placement_group_id @cluster_placement_group_id end |
#cpg_id ⇒ String
[Required] Cluster Placement Group OCID (deprecated representation)
52 53 54 |
# File 'lib/oci/multicloud/models/external_locations_metadatum_summary.rb', line 52 def cpg_id @cpg_id end |
#defined_tags ⇒ Hash<String, Hash<String, Object>>
[Required] Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags.
Example: {\"Operations\": {\"CostCenter\": \"42\"}}
25 26 27 |
# File 'lib/oci/multicloud/models/external_locations_metadatum_summary.rb', line 25 def @defined_tags end |
#external_location ⇒ OCI::Multicloud::Models::ExternalLocationDetail
This attribute is required.
36 37 38 |
# File 'lib/oci/multicloud/models/external_locations_metadatum_summary.rb', line 36 def external_location @external_location end |
#freeform_tags ⇒ Hash<String, String>
[Required] Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags.
Example: {\"Department\": \"Finance\"}
17 18 19 |
# File 'lib/oci/multicloud/models/external_locations_metadatum_summary.rb', line 17 def @freeform_tags end |
#oci_logical_ad ⇒ String
OCI logical ad name
44 45 46 |
# File 'lib/oci/multicloud/models/external_locations_metadatum_summary.rb', line 44 def oci_logical_ad @oci_logical_ad end |
#oci_physical_ad ⇒ String
[Required] OCI physical ad name
40 41 42 |
# File 'lib/oci/multicloud/models/external_locations_metadatum_summary.rb', line 40 def oci_physical_ad @oci_physical_ad end |
#oci_region ⇒ String
[Required] OCI region identifier docs.oracle.com/en-us/iaas/Content/General/Concepts/regions.htm
48 49 50 |
# File 'lib/oci/multicloud/models/external_locations_metadatum_summary.rb', line 48 def oci_region @oci_region end |
#partner_cloud_account_name ⇒ String
User friendly name of account name for customer's subscription
64 65 66 |
# File 'lib/oci/multicloud/models/external_locations_metadatum_summary.rb', line 64 def partner_cloud_account_name @partner_cloud_account_name end |
#partner_cloud_account_url ⇒ String
Direct URL to partner cloud for customer's account
68 69 70 |
# File 'lib/oci/multicloud/models/external_locations_metadatum_summary.rb', line 68 def partner_cloud_account_url @partner_cloud_account_url end |
#partner_cloud_name ⇒ String
Partner Cloud Name based on service name
60 61 62 |
# File 'lib/oci/multicloud/models/external_locations_metadatum_summary.rb', line 60 def partner_cloud_name @partner_cloud_name end |
#system_tags ⇒ Hash<String, Hash<String, Object>>
System tags for this resource. Each key is predefined and scoped to a namespace.
Example: {\"orcl-cloud\": {\"free-tier-retained\": \"true\"}}
32 33 34 |
# File 'lib/oci/multicloud/models/external_locations_metadatum_summary.rb', line 32 def @system_tags end |
Class Method Details
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 |
# File 'lib/oci/multicloud/models/external_locations_metadatum_summary.rb', line 71 def self.attribute_map { # rubocop:disable Style/SymbolLiteral 'freeform_tags': :'freeformTags', 'defined_tags': :'definedTags', 'system_tags': :'systemTags', 'external_location': :'externalLocation', 'oci_physical_ad': :'ociPhysicalAd', 'oci_logical_ad': :'ociLogicalAd', 'oci_region': :'ociRegion', 'cpg_id': :'cpgId', 'cluster_placement_group_id': :'clusterPlacementGroupId', 'partner_cloud_name': :'partnerCloudName', 'partner_cloud_account_name': :'partnerCloudAccountName', 'partner_cloud_account_url': :'partnerCloudAccountUrl' # rubocop:enable Style/SymbolLiteral } end |
.swagger_types ⇒ Object
Attribute type mapping.
91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 |
# File 'lib/oci/multicloud/models/external_locations_metadatum_summary.rb', line 91 def self.swagger_types { # rubocop:disable Style/SymbolLiteral 'freeform_tags': :'Hash<String, String>', 'defined_tags': :'Hash<String, Hash<String, Object>>', 'system_tags': :'Hash<String, Hash<String, Object>>', 'external_location': :'OCI::Multicloud::Models::ExternalLocationDetail', 'oci_physical_ad': :'String', 'oci_logical_ad': :'String', 'oci_region': :'String', 'cpg_id': :'String', 'cluster_placement_group_id': :'String', 'partner_cloud_name': :'String', 'partner_cloud_account_name': :'String', 'partner_cloud_account_url': :'String' # rubocop:enable Style/SymbolLiteral } end |
Instance Method Details
#==(other) ⇒ Object
Checks equality by comparing each attribute.
214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 |
# File 'lib/oci/multicloud/models/external_locations_metadatum_summary.rb', line 214 def ==(other) return true if equal?(other) self.class == other.class && == other. && == other. && == other. && external_location == other.external_location && oci_physical_ad == other.oci_physical_ad && oci_logical_ad == other.oci_logical_ad && oci_region == other.oci_region && cpg_id == other.cpg_id && cluster_placement_group_id == other.cluster_placement_group_id && partner_cloud_name == other.partner_cloud_name && partner_cloud_account_name == other.partner_cloud_account_name && partner_cloud_account_url == other.partner_cloud_account_url end |
#build_from_hash(attributes) ⇒ Object
Builds the object from hash
255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 |
# File 'lib/oci/multicloud/models/external_locations_metadatum_summary.rb', line 255 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
235 236 237 |
# File 'lib/oci/multicloud/models/external_locations_metadatum_summary.rb', line 235 def eql?(other) self == other end |
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
244 245 246 |
# File 'lib/oci/multicloud/models/external_locations_metadatum_summary.rb', line 244 def hash [, , , external_location, oci_physical_ad, oci_logical_ad, oci_region, cpg_id, cluster_placement_group_id, partner_cloud_name, partner_cloud_account_name, partner_cloud_account_url].hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
288 289 290 291 292 293 294 295 296 297 |
# File 'lib/oci/multicloud/models/external_locations_metadatum_summary.rb', line 288 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
282 283 284 |
# File 'lib/oci/multicloud/models/external_locations_metadatum_summary.rb', line 282 def to_s to_hash.to_s end |