oci 2.5.11 → 2.6.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +3 -1
- data/lib/oci.rb +1 -0
- data/lib/oci/auth/federation_client.rb +2 -1
- data/lib/oci/auth/signers/instance_principals_security_token_signer.rb +6 -1
- data/lib/oci/auth/url_based_certificate_retriever.rb +6 -2
- data/lib/oci/auth/util.rb +18 -0
- data/lib/oci/core/compute_client.rb +730 -48
- data/lib/oci/core/compute_client_composite_operations.rb +119 -0
- data/lib/oci/core/compute_management_client.rb +11 -4
- data/lib/oci/core/core.rb +13 -0
- data/lib/oci/core/models/add_security_rule_details.rb +4 -2
- data/lib/oci/core/models/attach_vnic_details.rb +1 -0
- data/lib/oci/core/models/capture_console_history_details.rb +1 -0
- data/lib/oci/core/models/change_dedicated_vm_host_compartment_details.rb +155 -0
- data/lib/oci/core/models/change_dhcp_options_compartment_details.rb +155 -0
- data/lib/oci/core/models/change_internet_gateway_compartment_details.rb +155 -0
- data/lib/oci/core/models/change_local_peering_gateway_compartment_details.rb +155 -0
- data/lib/oci/core/models/change_network_security_group_compartment_details.rb +155 -0
- data/lib/oci/core/models/change_public_ip_compartment_details.rb +155 -0
- data/lib/oci/core/models/create_dedicated_vm_host_details.rb +262 -0
- data/lib/oci/core/models/create_drg_attachment_details.rb +4 -2
- data/lib/oci/core/models/create_image_details.rb +1 -1
- data/lib/oci/core/models/create_instance_configuration_base.rb +16 -6
- data/lib/oci/core/models/create_instance_configuration_details.rb +1 -1
- data/lib/oci/core/models/create_instance_configuration_from_instance_details.rb +3 -2
- data/lib/oci/core/models/create_instance_pool_details.rb +3 -1
- data/lib/oci/core/models/create_local_peering_gateway_details.rb +1 -1
- data/lib/oci/core/models/create_service_gateway_details.rb +1 -1
- data/lib/oci/core/models/create_volume_group_backup_details.rb +3 -1
- data/lib/oci/core/models/create_volume_group_details.rb +1 -1
- data/lib/oci/core/models/cross_connect_mapping.rb +4 -0
- data/lib/oci/core/models/dedicated_vm_host.rb +359 -0
- data/lib/oci/core/models/dedicated_vm_host_instance_shape_summary.rb +170 -0
- data/lib/oci/core/models/dedicated_vm_host_instance_summary.rb +215 -0
- data/lib/oci/core/models/dedicated_vm_host_shape_summary.rb +171 -0
- data/lib/oci/core/models/dedicated_vm_host_summary.rb +325 -0
- data/lib/oci/core/models/drg_attachment.rb +6 -3
- data/lib/oci/core/models/egress_security_rule.rb +1 -0
- data/lib/oci/core/models/image.rb +2 -0
- data/lib/oci/core/models/ingress_security_rule.rb +2 -1
- data/lib/oci/core/models/instance.rb +16 -1
- data/lib/oci/core/models/instance_configuration.rb +10 -7
- data/lib/oci/core/models/ipv6.rb +2 -0
- data/lib/oci/core/models/launch_instance_details.rb +16 -1
- data/lib/oci/core/models/launch_options.rb +3 -2
- data/lib/oci/core/models/local_peering_gateway.rb +4 -3
- data/lib/oci/core/models/route_rule.rb +2 -1
- data/lib/oci/core/models/security_rule.rb +3 -1
- data/lib/oci/core/models/service_gateway.rb +4 -3
- data/lib/oci/core/models/subnet.rb +2 -1
- data/lib/oci/core/models/update_console_history_details.rb +1 -0
- data/lib/oci/core/models/update_dedicated_vm_host_details.rb +194 -0
- data/lib/oci/core/models/update_drg_attachment_details.rb +6 -3
- data/lib/oci/core/models/update_instance_pool_details.rb +3 -1
- data/lib/oci/core/models/update_local_peering_gateway_details.rb +4 -3
- data/lib/oci/core/models/update_network_security_group_details.rb +2 -0
- data/lib/oci/core/models/update_security_rule_details.rb +4 -2
- data/lib/oci/core/models/update_service_gateway_details.rb +4 -3
- data/lib/oci/core/models/update_vnic_details.rb +2 -0
- data/lib/oci/core/models/update_volume_backup_details.rb +1 -1
- data/lib/oci/core/models/update_volume_group_backup_details.rb +2 -1
- data/lib/oci/core/models/update_volume_group_details.rb +2 -1
- data/lib/oci/core/models/vcn.rb +2 -1
- data/lib/oci/core/models/volume_backup_schedule.rb +1 -1
- data/lib/oci/core/virtual_network_client.rb +396 -59
- data/lib/oci/dts/dts.rb +57 -0
- data/lib/oci/dts/models/attach_devices_details.rb +153 -0
- data/lib/oci/dts/models/change_transfer_job_compartment_details.rb +154 -0
- data/lib/oci/dts/models/create_transfer_appliance_details.rb +152 -0
- data/lib/oci/dts/models/create_transfer_appliance_entitlement_details.rb +178 -0
- data/lib/oci/dts/models/create_transfer_device_details.rb +165 -0
- data/lib/oci/dts/models/create_transfer_job_details.rb +238 -0
- data/lib/oci/dts/models/create_transfer_package_details.rb +178 -0
- data/lib/oci/dts/models/detach_devices_details.rb +153 -0
- data/lib/oci/dts/models/multiple_transfer_appliances.rb +153 -0
- data/lib/oci/dts/models/multiple_transfer_devices.rb +153 -0
- data/lib/oci/dts/models/multiple_transfer_packages.rb +153 -0
- data/lib/oci/dts/models/new_transfer_device.rb +246 -0
- data/lib/oci/dts/models/shipping_address.rb +263 -0
- data/lib/oci/dts/models/shipping_vendors.rb +149 -0
- data/lib/oci/dts/models/transfer_appliance.rb +367 -0
- data/lib/oci/dts/models/transfer_appliance_certificate.rb +148 -0
- data/lib/oci/dts/models/transfer_appliance_encryption_passphrase.rb +152 -0
- data/lib/oci/dts/models/transfer_appliance_entitlement.rb +240 -0
- data/lib/oci/dts/models/transfer_appliance_public_key.rb +152 -0
- data/lib/oci/dts/models/transfer_appliance_summary.rb +223 -0
- data/lib/oci/dts/models/transfer_device.rb +268 -0
- data/lib/oci/dts/models/transfer_device_summary.rb +254 -0
- data/lib/oci/dts/models/transfer_job.rb +356 -0
- data/lib/oci/dts/models/transfer_job_summary.rb +296 -0
- data/lib/oci/dts/models/transfer_package.rb +281 -0
- data/lib/oci/dts/models/transfer_package_summary.rb +201 -0
- data/lib/oci/dts/models/update_transfer_appliance_details.rb +180 -0
- data/lib/oci/dts/models/update_transfer_device_details.rb +166 -0
- data/lib/oci/dts/models/update_transfer_job_details.rb +237 -0
- data/lib/oci/dts/models/update_transfer_package_details.rb +204 -0
- data/lib/oci/dts/shipping_vendors_client.rb +165 -0
- data/lib/oci/dts/shipping_vendors_client_composite_operations.rb +24 -0
- data/lib/oci/dts/transfer_appliance_client.rb +569 -0
- data/lib/oci/dts/transfer_appliance_client_composite_operations.rb +104 -0
- data/lib/oci/dts/transfer_appliance_entitlement_client.rb +223 -0
- data/lib/oci/dts/transfer_appliance_entitlement_client_composite_operations.rb +24 -0
- data/lib/oci/dts/transfer_device_client.rb +402 -0
- data/lib/oci/dts/transfer_device_client_composite_operations.rb +65 -0
- data/lib/oci/dts/transfer_job_client.rb +458 -0
- data/lib/oci/dts/transfer_job_client_composite_operations.rb +143 -0
- data/lib/oci/dts/transfer_package_client.rb +515 -0
- data/lib/oci/dts/transfer_package_client_composite_operations.rb +104 -0
- data/lib/oci/dts/util.rb +2 -0
- data/lib/oci/file_storage/models/create_file_system_details.rb +19 -4
- data/lib/oci/file_storage/models/file_system.rb +19 -4
- data/lib/oci/file_storage/models/file_system_summary.rb +19 -4
- data/lib/oci/file_storage/models/update_file_system_details.rb +22 -4
- data/lib/oci/limits/limits.rb +5 -0
- data/lib/oci/limits/limits_client.rb +444 -0
- data/lib/oci/limits/limits_client_composite_operations.rb +24 -0
- data/lib/oci/limits/models/create_quota_details.rb +1 -1
- data/lib/oci/limits/models/limit_definition_summary.rb +241 -0
- data/lib/oci/limits/models/limit_value_summary.rb +210 -0
- data/lib/oci/limits/models/quota.rb +1 -1
- data/lib/oci/limits/models/resource_availability.rb +163 -0
- data/lib/oci/limits/models/service_summary.rb +159 -0
- data/lib/oci/limits/models/update_quota_details.rb +1 -1
- data/lib/oci/limits/quotas_client.rb +12 -11
- data/lib/oci/monitoring/models/alarm.rb +20 -1
- data/lib/oci/monitoring/models/create_alarm_details.rb +20 -1
- data/lib/oci/monitoring/models/list_metrics_details.rb +23 -3
- data/lib/oci/monitoring/models/metric.rb +20 -1
- data/lib/oci/monitoring/models/metric_data.rb +20 -1
- data/lib/oci/monitoring/models/metric_data_details.rb +20 -1
- data/lib/oci/monitoring/models/summarize_metrics_data_details.rb +20 -1
- data/lib/oci/monitoring/models/update_alarm_details.rb +20 -1
- data/lib/oci/regions.rb +14 -8
- data/lib/oci/streaming/models/archiver.rb +291 -0
- data/lib/oci/streaming/models/archiver_error.rb +159 -0
- data/lib/oci/streaming/models/archiver_lifecycle_state.rb +14 -0
- data/lib/oci/streaming/models/archiver_start_position.rb +10 -0
- data/lib/oci/streaming/models/create_archiver_details.rb +223 -0
- data/lib/oci/streaming/models/update_archiver_details.rb +222 -0
- data/lib/oci/streaming/stream_admin_client.rb +304 -0
- data/lib/oci/streaming/stream_admin_client_composite_operations.rb +162 -0
- data/lib/oci/streaming/streaming.rb +6 -0
- data/lib/oci/version.rb +1 -1
- data/lib/oci/waas/models/access_rule.rb +121 -4
- data/lib/oci/waas/models/access_rule_criteria.rb +12 -0
- data/lib/oci/waas/models/address_list.rb +289 -0
- data/lib/oci/waas/models/address_list_summary.rb +279 -0
- data/lib/oci/waas/models/caching_rule.rb +243 -0
- data/lib/oci/waas/models/caching_rule_criteria.rb +194 -0
- data/lib/oci/waas/models/caching_rule_summary.rb +246 -0
- data/lib/oci/waas/models/certificate.rb +22 -9
- data/lib/oci/waas/models/certificate_extensions.rb +3 -0
- data/lib/oci/waas/models/certificate_issuer_name.rb +225 -0
- data/lib/oci/waas/models/certificate_public_key_info.rb +4 -1
- data/lib/oci/waas/models/certificate_subject_name.rb +8 -1
- data/lib/oci/waas/models/certificate_summary.rb +10 -2
- data/lib/oci/waas/models/change_address_list_compartment_details.rb +154 -0
- data/lib/oci/waas/models/change_custom_protection_rule_compartment_details.rb +154 -0
- data/lib/oci/waas/models/create_address_list_details.rb +213 -0
- data/lib/oci/waas/models/create_certificate_details.rb +22 -3
- data/lib/oci/waas/models/create_custom_protection_rule_details.rb +251 -0
- data/lib/oci/waas/models/create_waas_policy_details.rb +26 -4
- data/lib/oci/waas/models/custom_protection_rule.rb +326 -0
- data/lib/oci/waas/models/custom_protection_rule_setting.rb +180 -0
- data/lib/oci/waas/models/custom_protection_rule_summary.rb +279 -0
- data/lib/oci/waas/models/origin_group.rb +149 -0
- data/lib/oci/waas/models/origin_group_origins.rb +159 -0
- data/lib/oci/waas/models/policy_config.rb +201 -4
- data/lib/oci/waas/models/protection_rule_exclusion.rb +2 -2
- data/lib/oci/waas/models/purge_cache.rb +149 -0
- data/lib/oci/waas/models/update_address_list_details.rb +199 -0
- data/lib/oci/waas/models/update_certificate_details.rb +10 -2
- data/lib/oci/waas/models/update_custom_protection_rule_details.rb +237 -0
- data/lib/oci/waas/models/update_waas_policy_details.rb +26 -4
- data/lib/oci/waas/models/waas_policy.rb +25 -3
- data/lib/oci/waas/models/waas_policy_custom_protection_rule_summary.rb +207 -0
- data/lib/oci/waas/models/waas_policy_summary.rb +10 -2
- data/lib/oci/waas/models/waf_config.rb +43 -1
- data/lib/oci/waas/models/waf_config_details.rb +43 -1
- data/lib/oci/waas/models/waf_log.rb +3 -3
- data/lib/oci/waas/models/work_request.rb +4 -1
- data/lib/oci/waas/models/work_request_operation_types.rb +4 -1
- data/lib/oci/waas/models/work_request_summary.rb +4 -1
- data/lib/oci/waas/waas.rb +19 -0
- data/lib/oci/waas/waas_client.rb +1147 -61
- data/lib/oci/waas/waas_client_composite_operations.rb +386 -0
- metadata +90 -2
@@ -5,7 +5,7 @@ require_relative 'create_instance_configuration_base'
|
|
5
5
|
|
6
6
|
# rubocop:disable Lint/UnneededCopDisableDirective, Metrics/LineLength
|
7
7
|
module OCI
|
8
|
-
#
|
8
|
+
# Details for creating an instance configuration by providing a list of configuration settings.
|
9
9
|
#
|
10
10
|
class Core::Models::CreateInstanceConfigurationDetails < Core::Models::CreateInstanceConfigurationBase
|
11
11
|
# This attribute is required.
|
@@ -5,10 +5,11 @@ require_relative 'create_instance_configuration_base'
|
|
5
5
|
|
6
6
|
# rubocop:disable Lint/UnneededCopDisableDirective, Metrics/LineLength
|
7
7
|
module OCI
|
8
|
-
#
|
8
|
+
# Details for creating an instance configuration using an existing instance as a template.
|
9
9
|
#
|
10
10
|
class Core::Models::CreateInstanceConfigurationFromInstanceDetails < Core::Models::CreateInstanceConfigurationBase
|
11
|
-
# **[Required]** The
|
11
|
+
# **[Required]** The [OCID](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance to use to create the
|
12
|
+
# instance configuration.
|
12
13
|
#
|
13
14
|
# @return [String]
|
14
15
|
attr_accessor :instance_id
|
@@ -18,7 +18,9 @@ module OCI
|
|
18
18
|
# @return [Hash<String, Hash<String, Object>>]
|
19
19
|
attr_accessor :defined_tags
|
20
20
|
|
21
|
-
#
|
21
|
+
# A user-friendly name for the instance pool. Does not have to be unique, and it's
|
22
|
+
# changeable. Avoid entering confidential information.
|
23
|
+
#
|
22
24
|
# @return [String]
|
23
25
|
attr_accessor :display_name
|
24
26
|
|
@@ -39,7 +39,7 @@ module OCI
|
|
39
39
|
# with the LPG.
|
40
40
|
#
|
41
41
|
# For information about why you would associate a route table with an LPG, see
|
42
|
-
# [
|
42
|
+
# [Transit Routing: Access to Multiple VCNs in Same Region](https://docs.cloud.oracle.com/Content/Network/Tasks/transitrouting.htm).
|
43
43
|
#
|
44
44
|
# @return [String]
|
45
45
|
attr_accessor :route_table_id
|
@@ -40,7 +40,7 @@ module OCI
|
|
40
40
|
# with the service gateway.
|
41
41
|
#
|
42
42
|
# For information about why you would associate a route table with a service gateway, see
|
43
|
-
# [Transit Routing: Private Access to Oracle Services
|
43
|
+
# [Transit Routing: Private Access to Oracle Services](https://docs.cloud.oracle.com/Content/Network/Tasks/transitroutingoracleservices.htm).
|
44
44
|
#
|
45
45
|
# @return [String]
|
46
46
|
attr_accessor :route_table_id
|
@@ -23,7 +23,9 @@ module OCI
|
|
23
23
|
# @return [Hash<String, Hash<String, Object>>]
|
24
24
|
attr_accessor :defined_tags
|
25
25
|
|
26
|
-
# A user-friendly name for the volume group backup. Does not have
|
26
|
+
# A user-friendly name for the volume group backup. Does not have
|
27
|
+
# to be unique and it's changeable. Avoid entering confidential information.
|
28
|
+
#
|
27
29
|
# @return [String]
|
28
30
|
attr_accessor :display_name
|
29
31
|
|
@@ -22,7 +22,7 @@ module OCI
|
|
22
22
|
# @return [Hash<String, Hash<String, Object>>]
|
23
23
|
attr_accessor :defined_tags
|
24
24
|
|
25
|
-
# A user-friendly name for the volume group. Does not have to be unique, and it's changeable.
|
25
|
+
# A user-friendly name for the volume group. Does not have to be unique, and it's changeable. Avoid entering confidential information.
|
26
26
|
# @return [String]
|
27
27
|
attr_accessor :display_name
|
28
28
|
|
@@ -83,6 +83,8 @@ module OCI
|
|
83
83
|
#
|
84
84
|
# There's one exception: for a public virtual circuit, Oracle specifies the BGP IPv6 addresses.
|
85
85
|
#
|
86
|
+
# Note that IPv6 addressing is currently supported only in the Government Cloud.
|
87
|
+
#
|
86
88
|
# Example: `2001:db8::1/64`
|
87
89
|
#
|
88
90
|
# @return [String]
|
@@ -95,6 +97,8 @@ module OCI
|
|
95
97
|
#
|
96
98
|
# There's one exception: for a public virtual circuit, Oracle specifies the BGP IPv6 addresses.
|
97
99
|
#
|
100
|
+
# Note that IPv6 addressing is currently supported only in the Government Cloud.
|
101
|
+
#
|
98
102
|
# Example: `2001:db8::2/64`
|
99
103
|
#
|
100
104
|
# @return [String]
|
@@ -0,0 +1,359 @@
|
|
1
|
+
# Copyright (c) 2016, 2019, Oracle and/or its affiliates. All rights reserved.
|
2
|
+
|
3
|
+
require 'date'
|
4
|
+
require 'logger'
|
5
|
+
|
6
|
+
# rubocop:disable Lint/UnneededCopDisableDirective, Metrics/LineLength
|
7
|
+
module OCI
|
8
|
+
# A dedicated virtual machine (VM) host that enables you to host multiple virtual machine instances on a dedicated host that is not shared with other tenancies.
|
9
|
+
#
|
10
|
+
class Core::Models::DedicatedVmHost
|
11
|
+
LIFECYCLE_STATE_ENUM = [
|
12
|
+
LIFECYCLE_STATE_CREATING = 'CREATING'.freeze,
|
13
|
+
LIFECYCLE_STATE_ACTIVE = 'ACTIVE'.freeze,
|
14
|
+
LIFECYCLE_STATE_UPDATING = 'UPDATING'.freeze,
|
15
|
+
LIFECYCLE_STATE_DELETING = 'DELETING'.freeze,
|
16
|
+
LIFECYCLE_STATE_DELETED = 'DELETED'.freeze,
|
17
|
+
LIFECYCLE_STATE_FAILED = 'FAILED'.freeze,
|
18
|
+
LIFECYCLE_STATE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze
|
19
|
+
].freeze
|
20
|
+
|
21
|
+
# **[Required]** The availability domain the dedicated VM host is running in.
|
22
|
+
#
|
23
|
+
# Example: `Uocm:PHX-AD-1`
|
24
|
+
#
|
25
|
+
# @return [String]
|
26
|
+
attr_accessor :availability_domain
|
27
|
+
|
28
|
+
# **[Required]** The OCID of the compartment that contains the dedicated VM host.
|
29
|
+
# @return [String]
|
30
|
+
attr_accessor :compartment_id
|
31
|
+
|
32
|
+
# **[Required]** The shape of the dedicated VM host. The shape determines the number of CPUs and
|
33
|
+
# other resources available for VMs.
|
34
|
+
#
|
35
|
+
# @return [String]
|
36
|
+
attr_accessor :dedicated_vm_host_shape
|
37
|
+
|
38
|
+
# Defined tags for this resource. Each key is predefined and scoped to a
|
39
|
+
# namespace. For more information, see [Resource Tags](https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm).
|
40
|
+
#
|
41
|
+
# Example: `{\"Operations\": {\"CostCenter\": \"42\"}}`
|
42
|
+
#
|
43
|
+
# @return [Hash<String, Hash<String, Object>>]
|
44
|
+
attr_accessor :defined_tags
|
45
|
+
|
46
|
+
# **[Required]** A user-friendly name. Does not have to be unique, and it's changeable.
|
47
|
+
# Avoid entering confidential information.
|
48
|
+
#
|
49
|
+
# Example: `My Dedicated Vm Host`
|
50
|
+
#
|
51
|
+
# @return [String]
|
52
|
+
attr_accessor :display_name
|
53
|
+
|
54
|
+
# The fault domain for the dedicated VM host's assigned instances. For more information, see Fault Domains.
|
55
|
+
#
|
56
|
+
# If you do not specify the fault domain, the system selects one for you. To change the fault domain for a dedicated VM host,
|
57
|
+
# delete it and create a new dedicated VM host in the preferred fault domain.
|
58
|
+
#
|
59
|
+
# To get a list of fault domains, use the ListFaultDomains operation in the Identity and Access Management Service API.
|
60
|
+
#
|
61
|
+
# Example: `FAULT-DOMAIN-1`
|
62
|
+
#
|
63
|
+
# @return [String]
|
64
|
+
attr_accessor :fault_domain
|
65
|
+
|
66
|
+
# Free-form tags for this resource. Each tag is a simple key-value pair with no
|
67
|
+
# predefined name, type, or namespace. For more information, see [Resource Tags](https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm).
|
68
|
+
#
|
69
|
+
# Example: `{\"Department\": \"Finance\"}`
|
70
|
+
#
|
71
|
+
# @return [Hash<String, String>]
|
72
|
+
attr_accessor :freeform_tags
|
73
|
+
|
74
|
+
# **[Required]** The OCID of the dedicated VM host.
|
75
|
+
# @return [String]
|
76
|
+
attr_accessor :id
|
77
|
+
|
78
|
+
# **[Required]** The current state of the dedicated VM host.
|
79
|
+
#
|
80
|
+
# @return [String]
|
81
|
+
attr_reader :lifecycle_state
|
82
|
+
|
83
|
+
# **[Required]** The date and time the dedicated VM host was created, in the format defined by RFC3339.
|
84
|
+
#
|
85
|
+
# Example: `2016-08-25T21:10:29.600Z`
|
86
|
+
#
|
87
|
+
# @return [DateTime]
|
88
|
+
attr_accessor :time_created
|
89
|
+
|
90
|
+
# **[Required]** The total OCPUs of the dedicated VM host.
|
91
|
+
#
|
92
|
+
# @return [Float]
|
93
|
+
attr_accessor :total_ocpus
|
94
|
+
|
95
|
+
# **[Required]** The available OCPUs of the dedicated VM host.
|
96
|
+
#
|
97
|
+
# @return [Float]
|
98
|
+
attr_accessor :remaining_ocpus
|
99
|
+
|
100
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
101
|
+
def self.attribute_map
|
102
|
+
{
|
103
|
+
# rubocop:disable Style/SymbolLiteral
|
104
|
+
'availability_domain': :'availabilityDomain',
|
105
|
+
'compartment_id': :'compartmentId',
|
106
|
+
'dedicated_vm_host_shape': :'dedicatedVmHostShape',
|
107
|
+
'defined_tags': :'definedTags',
|
108
|
+
'display_name': :'displayName',
|
109
|
+
'fault_domain': :'faultDomain',
|
110
|
+
'freeform_tags': :'freeformTags',
|
111
|
+
'id': :'id',
|
112
|
+
'lifecycle_state': :'lifecycleState',
|
113
|
+
'time_created': :'timeCreated',
|
114
|
+
'total_ocpus': :'totalOcpus',
|
115
|
+
'remaining_ocpus': :'remainingOcpus'
|
116
|
+
# rubocop:enable Style/SymbolLiteral
|
117
|
+
}
|
118
|
+
end
|
119
|
+
|
120
|
+
# Attribute type mapping.
|
121
|
+
def self.swagger_types
|
122
|
+
{
|
123
|
+
# rubocop:disable Style/SymbolLiteral
|
124
|
+
'availability_domain': :'String',
|
125
|
+
'compartment_id': :'String',
|
126
|
+
'dedicated_vm_host_shape': :'String',
|
127
|
+
'defined_tags': :'Hash<String, Hash<String, Object>>',
|
128
|
+
'display_name': :'String',
|
129
|
+
'fault_domain': :'String',
|
130
|
+
'freeform_tags': :'Hash<String, String>',
|
131
|
+
'id': :'String',
|
132
|
+
'lifecycle_state': :'String',
|
133
|
+
'time_created': :'DateTime',
|
134
|
+
'total_ocpus': :'Float',
|
135
|
+
'remaining_ocpus': :'Float'
|
136
|
+
# rubocop:enable Style/SymbolLiteral
|
137
|
+
}
|
138
|
+
end
|
139
|
+
|
140
|
+
# rubocop:disable Metrics/CyclomaticComplexity, Metrics/AbcSize, Metrics/PerceivedComplexity
|
141
|
+
# rubocop:disable Metrics/MethodLength, Layout/EmptyLines, Style/SymbolLiteral
|
142
|
+
|
143
|
+
|
144
|
+
# Initializes the object
|
145
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
146
|
+
# @option attributes [String] :availability_domain The value to assign to the {#availability_domain} property
|
147
|
+
# @option attributes [String] :compartment_id The value to assign to the {#compartment_id} property
|
148
|
+
# @option attributes [String] :dedicated_vm_host_shape The value to assign to the {#dedicated_vm_host_shape} property
|
149
|
+
# @option attributes [Hash<String, Hash<String, Object>>] :defined_tags The value to assign to the {#defined_tags} property
|
150
|
+
# @option attributes [String] :display_name The value to assign to the {#display_name} property
|
151
|
+
# @option attributes [String] :fault_domain The value to assign to the {#fault_domain} property
|
152
|
+
# @option attributes [Hash<String, String>] :freeform_tags The value to assign to the {#freeform_tags} property
|
153
|
+
# @option attributes [String] :id The value to assign to the {#id} property
|
154
|
+
# @option attributes [String] :lifecycle_state The value to assign to the {#lifecycle_state} property
|
155
|
+
# @option attributes [DateTime] :time_created The value to assign to the {#time_created} property
|
156
|
+
# @option attributes [Float] :total_ocpus The value to assign to the {#total_ocpus} property
|
157
|
+
# @option attributes [Float] :remaining_ocpus The value to assign to the {#remaining_ocpus} property
|
158
|
+
def initialize(attributes = {})
|
159
|
+
return unless attributes.is_a?(Hash)
|
160
|
+
|
161
|
+
# convert string to symbol for hash key
|
162
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
163
|
+
|
164
|
+
self.availability_domain = attributes[:'availabilityDomain'] if attributes[:'availabilityDomain']
|
165
|
+
|
166
|
+
raise 'You cannot provide both :availabilityDomain and :availability_domain' if attributes.key?(:'availabilityDomain') && attributes.key?(:'availability_domain')
|
167
|
+
|
168
|
+
self.availability_domain = attributes[:'availability_domain'] if attributes[:'availability_domain']
|
169
|
+
|
170
|
+
self.compartment_id = attributes[:'compartmentId'] if attributes[:'compartmentId']
|
171
|
+
|
172
|
+
raise 'You cannot provide both :compartmentId and :compartment_id' if attributes.key?(:'compartmentId') && attributes.key?(:'compartment_id')
|
173
|
+
|
174
|
+
self.compartment_id = attributes[:'compartment_id'] if attributes[:'compartment_id']
|
175
|
+
|
176
|
+
self.dedicated_vm_host_shape = attributes[:'dedicatedVmHostShape'] if attributes[:'dedicatedVmHostShape']
|
177
|
+
|
178
|
+
raise 'You cannot provide both :dedicatedVmHostShape and :dedicated_vm_host_shape' if attributes.key?(:'dedicatedVmHostShape') && attributes.key?(:'dedicated_vm_host_shape')
|
179
|
+
|
180
|
+
self.dedicated_vm_host_shape = attributes[:'dedicated_vm_host_shape'] if attributes[:'dedicated_vm_host_shape']
|
181
|
+
|
182
|
+
self.defined_tags = attributes[:'definedTags'] if attributes[:'definedTags']
|
183
|
+
|
184
|
+
raise 'You cannot provide both :definedTags and :defined_tags' if attributes.key?(:'definedTags') && attributes.key?(:'defined_tags')
|
185
|
+
|
186
|
+
self.defined_tags = attributes[:'defined_tags'] if attributes[:'defined_tags']
|
187
|
+
|
188
|
+
self.display_name = attributes[:'displayName'] if attributes[:'displayName']
|
189
|
+
|
190
|
+
raise 'You cannot provide both :displayName and :display_name' if attributes.key?(:'displayName') && attributes.key?(:'display_name')
|
191
|
+
|
192
|
+
self.display_name = attributes[:'display_name'] if attributes[:'display_name']
|
193
|
+
|
194
|
+
self.fault_domain = attributes[:'faultDomain'] if attributes[:'faultDomain']
|
195
|
+
|
196
|
+
raise 'You cannot provide both :faultDomain and :fault_domain' if attributes.key?(:'faultDomain') && attributes.key?(:'fault_domain')
|
197
|
+
|
198
|
+
self.fault_domain = attributes[:'fault_domain'] if attributes[:'fault_domain']
|
199
|
+
|
200
|
+
self.freeform_tags = attributes[:'freeformTags'] if attributes[:'freeformTags']
|
201
|
+
|
202
|
+
raise 'You cannot provide both :freeformTags and :freeform_tags' if attributes.key?(:'freeformTags') && attributes.key?(:'freeform_tags')
|
203
|
+
|
204
|
+
self.freeform_tags = attributes[:'freeform_tags'] if attributes[:'freeform_tags']
|
205
|
+
|
206
|
+
self.id = attributes[:'id'] if attributes[:'id']
|
207
|
+
|
208
|
+
self.lifecycle_state = attributes[:'lifecycleState'] if attributes[:'lifecycleState']
|
209
|
+
|
210
|
+
raise 'You cannot provide both :lifecycleState and :lifecycle_state' if attributes.key?(:'lifecycleState') && attributes.key?(:'lifecycle_state')
|
211
|
+
|
212
|
+
self.lifecycle_state = attributes[:'lifecycle_state'] if attributes[:'lifecycle_state']
|
213
|
+
|
214
|
+
self.time_created = attributes[:'timeCreated'] if attributes[:'timeCreated']
|
215
|
+
|
216
|
+
raise 'You cannot provide both :timeCreated and :time_created' if attributes.key?(:'timeCreated') && attributes.key?(:'time_created')
|
217
|
+
|
218
|
+
self.time_created = attributes[:'time_created'] if attributes[:'time_created']
|
219
|
+
|
220
|
+
self.total_ocpus = attributes[:'totalOcpus'] if attributes[:'totalOcpus']
|
221
|
+
|
222
|
+
raise 'You cannot provide both :totalOcpus and :total_ocpus' if attributes.key?(:'totalOcpus') && attributes.key?(:'total_ocpus')
|
223
|
+
|
224
|
+
self.total_ocpus = attributes[:'total_ocpus'] if attributes[:'total_ocpus']
|
225
|
+
|
226
|
+
self.remaining_ocpus = attributes[:'remainingOcpus'] if attributes[:'remainingOcpus']
|
227
|
+
|
228
|
+
raise 'You cannot provide both :remainingOcpus and :remaining_ocpus' if attributes.key?(:'remainingOcpus') && attributes.key?(:'remaining_ocpus')
|
229
|
+
|
230
|
+
self.remaining_ocpus = attributes[:'remaining_ocpus'] if attributes[:'remaining_ocpus']
|
231
|
+
end
|
232
|
+
# rubocop:enable Metrics/CyclomaticComplexity, Metrics/AbcSize, Metrics/PerceivedComplexity
|
233
|
+
# rubocop:enable Metrics/MethodLength, Layout/EmptyLines, Style/SymbolLiteral
|
234
|
+
|
235
|
+
# Custom attribute writer method checking allowed values (enum).
|
236
|
+
# @param [Object] lifecycle_state Object to be assigned
|
237
|
+
def lifecycle_state=(lifecycle_state)
|
238
|
+
# rubocop:disable Style/ConditionalAssignment
|
239
|
+
if lifecycle_state && !LIFECYCLE_STATE_ENUM.include?(lifecycle_state)
|
240
|
+
OCI.logger.debug("Unknown value for 'lifecycle_state' [" + lifecycle_state + "]. Mapping to 'LIFECYCLE_STATE_UNKNOWN_ENUM_VALUE'") if OCI.logger
|
241
|
+
@lifecycle_state = LIFECYCLE_STATE_UNKNOWN_ENUM_VALUE
|
242
|
+
else
|
243
|
+
@lifecycle_state = lifecycle_state
|
244
|
+
end
|
245
|
+
# rubocop:enable Style/ConditionalAssignment
|
246
|
+
end
|
247
|
+
|
248
|
+
# rubocop:disable Metrics/CyclomaticComplexity, Metrics/AbcSize, Metrics/PerceivedComplexity, Layout/EmptyLines
|
249
|
+
|
250
|
+
|
251
|
+
# Checks equality by comparing each attribute.
|
252
|
+
# @param [Object] other the other object to be compared
|
253
|
+
def ==(other)
|
254
|
+
return true if equal?(other)
|
255
|
+
|
256
|
+
self.class == other.class &&
|
257
|
+
availability_domain == other.availability_domain &&
|
258
|
+
compartment_id == other.compartment_id &&
|
259
|
+
dedicated_vm_host_shape == other.dedicated_vm_host_shape &&
|
260
|
+
defined_tags == other.defined_tags &&
|
261
|
+
display_name == other.display_name &&
|
262
|
+
fault_domain == other.fault_domain &&
|
263
|
+
freeform_tags == other.freeform_tags &&
|
264
|
+
id == other.id &&
|
265
|
+
lifecycle_state == other.lifecycle_state &&
|
266
|
+
time_created == other.time_created &&
|
267
|
+
total_ocpus == other.total_ocpus &&
|
268
|
+
remaining_ocpus == other.remaining_ocpus
|
269
|
+
end
|
270
|
+
# rubocop:enable Metrics/CyclomaticComplexity, Metrics/AbcSize, Metrics/PerceivedComplexity, Layout/EmptyLines
|
271
|
+
|
272
|
+
# @see the `==` method
|
273
|
+
# @param [Object] other the other object to be compared
|
274
|
+
def eql?(other)
|
275
|
+
self == other
|
276
|
+
end
|
277
|
+
|
278
|
+
# rubocop:disable Metrics/AbcSize, Layout/EmptyLines
|
279
|
+
|
280
|
+
|
281
|
+
# Calculates hash code according to all attributes.
|
282
|
+
# @return [Fixnum] Hash code
|
283
|
+
def hash
|
284
|
+
[availability_domain, compartment_id, dedicated_vm_host_shape, defined_tags, display_name, fault_domain, freeform_tags, id, lifecycle_state, time_created, total_ocpus, remaining_ocpus].hash
|
285
|
+
end
|
286
|
+
# rubocop:enable Metrics/AbcSize, Layout/EmptyLines
|
287
|
+
|
288
|
+
# rubocop:disable Metrics/AbcSize, Layout/EmptyLines
|
289
|
+
|
290
|
+
|
291
|
+
# Builds the object from hash
|
292
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
293
|
+
# @return [Object] Returns the model itself
|
294
|
+
def build_from_hash(attributes)
|
295
|
+
return nil unless attributes.is_a?(Hash)
|
296
|
+
|
297
|
+
self.class.swagger_types.each_pair do |key, type|
|
298
|
+
if type =~ /^Array<(.*)>/i
|
299
|
+
# check to ensure the input is an array given that the the attribute
|
300
|
+
# is documented as an array but the input is not
|
301
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
302
|
+
public_method("#{key}=").call(
|
303
|
+
attributes[self.class.attribute_map[key]]
|
304
|
+
.map { |v| OCI::Internal::Util.convert_to_type(Regexp.last_match(1), v) }
|
305
|
+
)
|
306
|
+
end
|
307
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
308
|
+
public_method("#{key}=").call(
|
309
|
+
OCI::Internal::Util.convert_to_type(type, attributes[self.class.attribute_map[key]])
|
310
|
+
)
|
311
|
+
end
|
312
|
+
# or else data not found in attributes(hash), not an issue as the data can be optional
|
313
|
+
end
|
314
|
+
|
315
|
+
self
|
316
|
+
end
|
317
|
+
# rubocop:enable Metrics/AbcSize, Layout/EmptyLines
|
318
|
+
|
319
|
+
# Returns the string representation of the object
|
320
|
+
# @return [String] String presentation of the object
|
321
|
+
def to_s
|
322
|
+
to_hash.to_s
|
323
|
+
end
|
324
|
+
|
325
|
+
# Returns the object in the form of hash
|
326
|
+
# @return [Hash] Returns the object in the form of hash
|
327
|
+
def to_hash
|
328
|
+
hash = {}
|
329
|
+
self.class.attribute_map.each_pair do |attr, param|
|
330
|
+
value = public_method(attr).call
|
331
|
+
next if value.nil? && !instance_variable_defined?("@#{attr}")
|
332
|
+
|
333
|
+
hash[param] = _to_hash(value)
|
334
|
+
end
|
335
|
+
hash
|
336
|
+
end
|
337
|
+
|
338
|
+
private
|
339
|
+
|
340
|
+
# Outputs non-array value in the form of hash
|
341
|
+
# For object, use to_hash. Otherwise, just return the value
|
342
|
+
# @param [Object] value Any valid value
|
343
|
+
# @return [Hash] Returns the value in the form of hash
|
344
|
+
def _to_hash(value)
|
345
|
+
if value.is_a?(Array)
|
346
|
+
value.compact.map { |v| _to_hash(v) }
|
347
|
+
elsif value.is_a?(Hash)
|
348
|
+
{}.tap do |hash|
|
349
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
350
|
+
end
|
351
|
+
elsif value.respond_to? :to_hash
|
352
|
+
value.to_hash
|
353
|
+
else
|
354
|
+
value
|
355
|
+
end
|
356
|
+
end
|
357
|
+
end
|
358
|
+
end
|
359
|
+
# rubocop:enable Lint/UnneededCopDisableDirective, Metrics/LineLength
|