Class: OCI::Database::Models::CreateExadataInfrastructureDetails

Inherits:
Object
  • Object
show all
Defined in:
lib/oci/database/models/create_exadata_infrastructure_details.rb

Overview

Request to create Exadata infrastructure.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(attributes = {}) ⇒ CreateExadataInfrastructureDetails

Initializes the object

Parameters:

  • attributes (Hash) (defaults to: {})

    Model attributes in the form of hash

Options Hash (attributes):

  • :compartment_id (String)

    The value to assign to the #compartment_id property

  • :display_name (String)

    The value to assign to the #display_name property

  • :shape (String)

    The value to assign to the #shape property

  • :time_zone (String)

    The value to assign to the #time_zone property

  • :cloud_control_plane_server1 (String)

    The value to assign to the #cloud_control_plane_server1 property

  • :cloud_control_plane_server2 (String)

    The value to assign to the #cloud_control_plane_server2 property

  • :netmask (String)

    The value to assign to the #netmask property

  • :gateway (String)

    The value to assign to the #gateway property

  • :admin_network_cidr (String)

    The value to assign to the #admin_network_cidr property

  • :infini_band_network_cidr (String)

    The value to assign to the #infini_band_network_cidr property

  • :corporate_proxy (String)

    The value to assign to the #corporate_proxy property

  • :dns_server (Array<String>)

    The value to assign to the #dns_server property

  • :ntp_server (Array<String>)

    The value to assign to the #ntp_server property

  • :freeform_tags (Hash<String, String>)

    The value to assign to the #freeform_tags property

  • :defined_tags (Hash<String, Hash<String, Object>>)

    The value to assign to the #defined_tags property



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
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
# File 'lib/oci/database/models/create_exadata_infrastructure_details.rb', line 147

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.compartment_id = attributes[:'compartmentId'] if attributes[:'compartmentId']

  raise 'You cannot provide both :compartmentId and :compartment_id' if attributes.key?(:'compartmentId') && attributes.key?(:'compartment_id')

  self.compartment_id = attributes[:'compartment_id'] if attributes[:'compartment_id']

  self.display_name = attributes[:'displayName'] if attributes[:'displayName']

  raise 'You cannot provide both :displayName and :display_name' if attributes.key?(:'displayName') && attributes.key?(:'display_name')

  self.display_name = attributes[:'display_name'] if attributes[:'display_name']

  self.shape = attributes[:'shape'] if attributes[:'shape']

  self.time_zone = attributes[:'timeZone'] if attributes[:'timeZone']

  raise 'You cannot provide both :timeZone and :time_zone' if attributes.key?(:'timeZone') && attributes.key?(:'time_zone')

  self.time_zone = attributes[:'time_zone'] if attributes[:'time_zone']

  self.cloud_control_plane_server1 = attributes[:'cloudControlPlaneServer1'] if attributes[:'cloudControlPlaneServer1']

  raise 'You cannot provide both :cloudControlPlaneServer1 and :cloud_control_plane_server1' if attributes.key?(:'cloudControlPlaneServer1') && attributes.key?(:'cloud_control_plane_server1')

  self.cloud_control_plane_server1 = attributes[:'cloud_control_plane_server1'] if attributes[:'cloud_control_plane_server1']

  self.cloud_control_plane_server2 = attributes[:'cloudControlPlaneServer2'] if attributes[:'cloudControlPlaneServer2']

  raise 'You cannot provide both :cloudControlPlaneServer2 and :cloud_control_plane_server2' if attributes.key?(:'cloudControlPlaneServer2') && attributes.key?(:'cloud_control_plane_server2')

  self.cloud_control_plane_server2 = attributes[:'cloud_control_plane_server2'] if attributes[:'cloud_control_plane_server2']

  self.netmask = attributes[:'netmask'] if attributes[:'netmask']

  self.gateway = attributes[:'gateway'] if attributes[:'gateway']

  self.admin_network_cidr = attributes[:'adminNetworkCIDR'] if attributes[:'adminNetworkCIDR']

  raise 'You cannot provide both :adminNetworkCIDR and :admin_network_cidr' if attributes.key?(:'adminNetworkCIDR') && attributes.key?(:'admin_network_cidr')

  self.admin_network_cidr = attributes[:'admin_network_cidr'] if attributes[:'admin_network_cidr']

  self.infini_band_network_cidr = attributes[:'infiniBandNetworkCIDR'] if attributes[:'infiniBandNetworkCIDR']

  raise 'You cannot provide both :infiniBandNetworkCIDR and :infini_band_network_cidr' if attributes.key?(:'infiniBandNetworkCIDR') && attributes.key?(:'infini_band_network_cidr')

  self.infini_band_network_cidr = attributes[:'infini_band_network_cidr'] if attributes[:'infini_band_network_cidr']

  self.corporate_proxy = attributes[:'corporateProxy'] if attributes[:'corporateProxy']

  raise 'You cannot provide both :corporateProxy and :corporate_proxy' if attributes.key?(:'corporateProxy') && attributes.key?(:'corporate_proxy')

  self.corporate_proxy = attributes[:'corporate_proxy'] if attributes[:'corporate_proxy']

  self.dns_server = attributes[:'dnsServer'] if attributes[:'dnsServer']

  raise 'You cannot provide both :dnsServer and :dns_server' if attributes.key?(:'dnsServer') && attributes.key?(:'dns_server')

  self.dns_server = attributes[:'dns_server'] if attributes[:'dns_server']

  self.ntp_server = attributes[:'ntpServer'] if attributes[:'ntpServer']

  raise 'You cannot provide both :ntpServer and :ntp_server' if attributes.key?(:'ntpServer') && attributes.key?(:'ntp_server')

  self.ntp_server = attributes[:'ntp_server'] if attributes[:'ntp_server']

  self.freeform_tags = attributes[:'freeformTags'] if attributes[:'freeformTags']

  raise 'You cannot provide both :freeformTags and :freeform_tags' if attributes.key?(:'freeformTags') && attributes.key?(:'freeform_tags')

  self.freeform_tags = attributes[:'freeform_tags'] if attributes[:'freeform_tags']

  self.defined_tags = attributes[:'definedTags'] if attributes[:'definedTags']

  raise 'You cannot provide both :definedTags and :defined_tags' if attributes.key?(:'definedTags') && attributes.key?(:'defined_tags')

  self.defined_tags = attributes[:'defined_tags'] if attributes[:'defined_tags']
end

Instance Attribute Details

#admin_network_cidrString

[Required] The CIDR block for the Exadata administration network.

Returns:

  • (String)


48
49
50
# File 'lib/oci/database/models/create_exadata_infrastructure_details.rb', line 48

def admin_network_cidr
  @admin_network_cidr
end

#cloud_control_plane_server1String

[Required] The IP address for the first control plane server.

Returns:

  • (String)


32
33
34
# File 'lib/oci/database/models/create_exadata_infrastructure_details.rb', line 32

def cloud_control_plane_server1
  @cloud_control_plane_server1
end

#cloud_control_plane_server2String

[Required] The IP address for the second control plane server.

Returns:

  • (String)


36
37
38
# File 'lib/oci/database/models/create_exadata_infrastructure_details.rb', line 36

def cloud_control_plane_server2
  @cloud_control_plane_server2
end

#compartment_idString

[Required] The [OCID](docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the compartment.

Returns:

  • (String)


13
14
15
# File 'lib/oci/database/models/create_exadata_infrastructure_details.rb', line 13

def compartment_id
  @compartment_id
end

#corporate_proxyString

[Required] The corporate network proxy for access to the control plane network.

Returns:

  • (String)


56
57
58
# File 'lib/oci/database/models/create_exadata_infrastructure_details.rb', line 56

def corporate_proxy
  @corporate_proxy
end

#defined_tagsHash<String, Hash<String, Object>>

Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see [Resource Tags](docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm).

Returns:

  • (Hash<String, Hash<String, Object>>)


78
79
80
# File 'lib/oci/database/models/create_exadata_infrastructure_details.rb', line 78

def defined_tags
  @defined_tags
end

#display_nameString

[Required] The user-friendly name for the Exadata infrastructure. The name does not need to be unique.

Returns:

  • (String)


18
19
20
# File 'lib/oci/database/models/create_exadata_infrastructure_details.rb', line 18

def display_name
  @display_name
end

#dns_serverArray<String>

[Required] The list of DNS server IP addresses. Maximum of 3 allowed.

Returns:

  • (Array<String>)


60
61
62
# File 'lib/oci/database/models/create_exadata_infrastructure_details.rb', line 60

def dns_server
  @dns_server
end

#freeform_tagsHash<String, String>

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](docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm).

Example: ‘"Finance"`

Returns:

  • (Hash<String, String>)


72
73
74
# File 'lib/oci/database/models/create_exadata_infrastructure_details.rb', line 72

def freeform_tags
  @freeform_tags
end

#gatewayString

[Required] The gateway for the control plane network.

Returns:

  • (String)


44
45
46
# File 'lib/oci/database/models/create_exadata_infrastructure_details.rb', line 44

def gateway
  @gateway
end

#infini_band_network_cidrString

[Required] The CIDR block for the Exadata InfiniBand interconnect.

Returns:

  • (String)


52
53
54
# File 'lib/oci/database/models/create_exadata_infrastructure_details.rb', line 52

def infini_band_network_cidr
  @infini_band_network_cidr
end

#netmaskString

[Required] The netmask for the control plane network.

Returns:

  • (String)


40
41
42
# File 'lib/oci/database/models/create_exadata_infrastructure_details.rb', line 40

def netmask
  @netmask
end

#ntp_serverArray<String>

[Required] The list of NTP server IP addresses. Maximum of 3 allowed.

Returns:

  • (Array<String>)


64
65
66
# File 'lib/oci/database/models/create_exadata_infrastructure_details.rb', line 64

def ntp_server
  @ntp_server
end

#shapeString

[Required] The shape of the Exadata infrastructure. The shape determines the amount of CPU, storage, and memory resources allocated to the instance.

Returns:

  • (String)


23
24
25
# File 'lib/oci/database/models/create_exadata_infrastructure_details.rb', line 23

def shape
  @shape
end

#time_zoneString

[Required] The time zone of the Exadata infrastructure. For details, see [Exadata Infrastructure Time Zones](docs.cloud.oracle.com/Content/Database/References/timezones.htm).

Returns:

  • (String)


28
29
30
# File 'lib/oci/database/models/create_exadata_infrastructure_details.rb', line 28

def time_zone
  @time_zone
end

Class Method Details

.attribute_mapObject

Attribute mapping from ruby-style variable name to JSON key.



81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
# File 'lib/oci/database/models/create_exadata_infrastructure_details.rb', line 81

def self.attribute_map
  {
    # rubocop:disable Style/SymbolLiteral
    'compartment_id': :'compartmentId',
    'display_name': :'displayName',
    'shape': :'shape',
    'time_zone': :'timeZone',
    'cloud_control_plane_server1': :'cloudControlPlaneServer1',
    'cloud_control_plane_server2': :'cloudControlPlaneServer2',
    'netmask': :'netmask',
    'gateway': :'gateway',
    'admin_network_cidr': :'adminNetworkCIDR',
    'infini_band_network_cidr': :'infiniBandNetworkCIDR',
    'corporate_proxy': :'corporateProxy',
    'dns_server': :'dnsServer',
    'ntp_server': :'ntpServer',
    'freeform_tags': :'freeformTags',
    'defined_tags': :'definedTags'
    # rubocop:enable Style/SymbolLiteral
  }
end

.swagger_typesObject

Attribute type mapping.



104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
# File 'lib/oci/database/models/create_exadata_infrastructure_details.rb', line 104

def self.swagger_types
  {
    # rubocop:disable Style/SymbolLiteral
    'compartment_id': :'String',
    'display_name': :'String',
    'shape': :'String',
    'time_zone': :'String',
    'cloud_control_plane_server1': :'String',
    'cloud_control_plane_server2': :'String',
    'netmask': :'String',
    'gateway': :'String',
    'admin_network_cidr': :'String',
    'infini_band_network_cidr': :'String',
    'corporate_proxy': :'String',
    'dns_server': :'Array<String>',
    'ntp_server': :'Array<String>',
    'freeform_tags': :'Hash<String, String>',
    'defined_tags': :'Hash<String, Hash<String, Object>>'
    # rubocop:enable Style/SymbolLiteral
  }
end

Instance Method Details

#==(other) ⇒ Object

Checks equality by comparing each attribute.

Parameters:

  • other (Object)

    the other object to be compared



239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
# File 'lib/oci/database/models/create_exadata_infrastructure_details.rb', line 239

def ==(other)
  return true if equal?(other)

  self.class == other.class &&
    compartment_id == other.compartment_id &&
    display_name == other.display_name &&
    shape == other.shape &&
    time_zone == other.time_zone &&
    cloud_control_plane_server1 == other.cloud_control_plane_server1 &&
    cloud_control_plane_server2 == other.cloud_control_plane_server2 &&
    netmask == other.netmask &&
    gateway == other.gateway &&
    admin_network_cidr == other.admin_network_cidr &&
    infini_band_network_cidr == other.infini_band_network_cidr &&
    corporate_proxy == other.corporate_proxy &&
    dns_server == other.dns_server &&
    ntp_server == other.ntp_server &&
    freeform_tags == other.freeform_tags &&
    defined_tags == other.defined_tags
end

#build_from_hash(attributes) ⇒ Object

Builds the object from hash

Parameters:

  • attributes (Hash)

    Model attributes in the form of hash

Returns:

  • (Object)

    Returns the model itself



283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
# File 'lib/oci/database/models/create_exadata_infrastructure_details.rb', line 283

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

Parameters:

  • other (Object)

    the other object to be compared

Returns:

  • (Boolean)

See Also:

  • `==` method


263
264
265
# File 'lib/oci/database/models/create_exadata_infrastructure_details.rb', line 263

def eql?(other)
  self == other
end

#hashFixnum

Calculates hash code according to all attributes.

Returns:

  • (Fixnum)

    Hash code



272
273
274
# File 'lib/oci/database/models/create_exadata_infrastructure_details.rb', line 272

def hash
  [compartment_id, display_name, shape, time_zone, cloud_control_plane_server1, cloud_control_plane_server2, netmask, gateway, admin_network_cidr, infini_band_network_cidr, corporate_proxy, dns_server, ntp_server, freeform_tags, defined_tags].hash
end

#to_hashHash

Returns the object in the form of hash

Returns:

  • (Hash)

    Returns the object in the form of hash



316
317
318
319
320
321
322
323
324
325
# File 'lib/oci/database/models/create_exadata_infrastructure_details.rb', line 316

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_sString

Returns the string representation of the object

Returns:

  • (String)

    String presentation of the object



310
311
312
# File 'lib/oci/database/models/create_exadata_infrastructure_details.rb', line 310

def to_s
  to_hash.to_s
end