oraclebmc 1.2.4 → 2.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (186) hide show
  1. checksums.yaml +4 -4
  2. data/{README.md → README_BMCS.md} +21 -26
  3. data/lib/oraclebmc.rb +1 -19
  4. metadata +16 -259
  5. data/lib/oraclebmc/api_client.rb +0 -306
  6. data/lib/oraclebmc/config.rb +0 -80
  7. data/lib/oraclebmc/config_file_loader.rb +0 -85
  8. data/lib/oraclebmc/core/blockstorage_client.rb +0 -460
  9. data/lib/oraclebmc/core/compute_client.rb +0 -1267
  10. data/lib/oraclebmc/core/core.rb +0 -112
  11. data/lib/oraclebmc/core/models/attach_i_scsi_volume_details.rb +0 -137
  12. data/lib/oraclebmc/core/models/attach_vnic_details.rb +0 -144
  13. data/lib/oraclebmc/core/models/attach_volume_details.rb +0 -165
  14. data/lib/oraclebmc/core/models/capture_console_history_details.rb +0 -120
  15. data/lib/oraclebmc/core/models/console_history.rb +0 -213
  16. data/lib/oraclebmc/core/models/cpe.rb +0 -169
  17. data/lib/oraclebmc/core/models/create_cpe_details.rb +0 -145
  18. data/lib/oraclebmc/core/models/create_cross_connect_details.rb +0 -204
  19. data/lib/oraclebmc/core/models/create_cross_connect_group_details.rb +0 -133
  20. data/lib/oraclebmc/core/models/create_dhcp_details.rb +0 -153
  21. data/lib/oraclebmc/core/models/create_drg_attachment_details.rb +0 -142
  22. data/lib/oraclebmc/core/models/create_drg_details.rb +0 -131
  23. data/lib/oraclebmc/core/models/create_image_details.rb +0 -159
  24. data/lib/oraclebmc/core/models/create_internet_gateway_details.rb +0 -153
  25. data/lib/oraclebmc/core/models/create_ip_sec_connection_details.rb +0 -168
  26. data/lib/oraclebmc/core/models/create_private_ip_details.rb +0 -173
  27. data/lib/oraclebmc/core/models/create_route_table_details.rb +0 -153
  28. data/lib/oraclebmc/core/models/create_security_list_details.rb +0 -164
  29. data/lib/oraclebmc/core/models/create_subnet_details.rb +0 -257
  30. data/lib/oraclebmc/core/models/create_vcn_details.rb +0 -171
  31. data/lib/oraclebmc/core/models/create_virtual_circuit_details.rb +0 -260
  32. data/lib/oraclebmc/core/models/create_vnic_details.rb +0 -214
  33. data/lib/oraclebmc/core/models/create_volume_backup_details.rb +0 -133
  34. data/lib/oraclebmc/core/models/create_volume_details.rb +0 -170
  35. data/lib/oraclebmc/core/models/cross_connect.rb +0 -235
  36. data/lib/oraclebmc/core/models/cross_connect_group.rb +0 -187
  37. data/lib/oraclebmc/core/models/cross_connect_location.rb +0 -134
  38. data/lib/oraclebmc/core/models/cross_connect_mapping.rb +0 -190
  39. data/lib/oraclebmc/core/models/cross_connect_port_speed_shape.rb +0 -137
  40. data/lib/oraclebmc/core/models/cross_connect_status.rb +0 -200
  41. data/lib/oraclebmc/core/models/dhcp_dns_option.rb +0 -171
  42. data/lib/oraclebmc/core/models/dhcp_option.rb +0 -135
  43. data/lib/oraclebmc/core/models/dhcp_options.rb +0 -208
  44. data/lib/oraclebmc/core/models/dhcp_search_domain_option.rb +0 -141
  45. data/lib/oraclebmc/core/models/drg.rb +0 -186
  46. data/lib/oraclebmc/core/models/drg_attachment.rb +0 -208
  47. data/lib/oraclebmc/core/models/egress_security_rule.rb +0 -198
  48. data/lib/oraclebmc/core/models/export_image_details.rb +0 -134
  49. data/lib/oraclebmc/core/models/export_image_via_object_storage_tuple_details.rb +0 -150
  50. data/lib/oraclebmc/core/models/export_image_via_object_storage_uri_details.rb +0 -130
  51. data/lib/oraclebmc/core/models/fast_connect_provider_service.rb +0 -145
  52. data/lib/oraclebmc/core/models/i_scsi_volume_attachment.rb +0 -212
  53. data/lib/oraclebmc/core/models/icmp_options.rb +0 -131
  54. data/lib/oraclebmc/core/models/image.rb +0 -245
  55. data/lib/oraclebmc/core/models/image_source_details.rb +0 -134
  56. data/lib/oraclebmc/core/models/image_source_via_object_storage_tuple_details.rb +0 -150
  57. data/lib/oraclebmc/core/models/image_source_via_object_storage_uri_details.rb +0 -128
  58. data/lib/oraclebmc/core/models/ingress_security_rule.rb +0 -198
  59. data/lib/oraclebmc/core/models/instance.rb +0 -307
  60. data/lib/oraclebmc/core/models/instance_credentials.rb +0 -131
  61. data/lib/oraclebmc/core/models/internet_gateway.rb +0 -210
  62. data/lib/oraclebmc/core/models/ip_sec_connection.rb +0 -223
  63. data/lib/oraclebmc/core/models/ip_sec_connection_device_config.rb +0 -153
  64. data/lib/oraclebmc/core/models/ip_sec_connection_device_status.rb +0 -156
  65. data/lib/oraclebmc/core/models/launch_instance_details.rb +0 -336
  66. data/lib/oraclebmc/core/models/letter_of_authority.rb +0 -194
  67. data/lib/oraclebmc/core/models/port_range.rb +0 -133
  68. data/lib/oraclebmc/core/models/private_ip.rb +0 -248
  69. data/lib/oraclebmc/core/models/route_rule.rb +0 -135
  70. data/lib/oraclebmc/core/models/route_table.rb +0 -208
  71. data/lib/oraclebmc/core/models/security_list.rb +0 -219
  72. data/lib/oraclebmc/core/models/shape.rb +0 -122
  73. data/lib/oraclebmc/core/models/subnet.rb +0 -351
  74. data/lib/oraclebmc/core/models/tcp_options.rb +0 -135
  75. data/lib/oraclebmc/core/models/tunnel_config.rb +0 -151
  76. data/lib/oraclebmc/core/models/tunnel_status.rb +0 -178
  77. data/lib/oraclebmc/core/models/udp_options.rb +0 -135
  78. data/lib/oraclebmc/core/models/update_cpe_details.rb +0 -122
  79. data/lib/oraclebmc/core/models/update_cross_connect_details.rb +0 -138
  80. data/lib/oraclebmc/core/models/update_cross_connect_group_details.rb +0 -122
  81. data/lib/oraclebmc/core/models/update_dhcp_details.rb +0 -132
  82. data/lib/oraclebmc/core/models/update_drg_attachment_details.rb +0 -122
  83. data/lib/oraclebmc/core/models/update_drg_details.rb +0 -122
  84. data/lib/oraclebmc/core/models/update_image_details.rb +0 -124
  85. data/lib/oraclebmc/core/models/update_instance_details.rb +0 -124
  86. data/lib/oraclebmc/core/models/update_internet_gateway_details.rb +0 -133
  87. data/lib/oraclebmc/core/models/update_ip_sec_connection_details.rb +0 -122
  88. data/lib/oraclebmc/core/models/update_private_ip_details.rb +0 -157
  89. data/lib/oraclebmc/core/models/update_route_table_details.rb +0 -133
  90. data/lib/oraclebmc/core/models/update_security_list_details.rb +0 -144
  91. data/lib/oraclebmc/core/models/update_subnet_details.rb +0 -122
  92. data/lib/oraclebmc/core/models/update_vcn_details.rb +0 -122
  93. data/lib/oraclebmc/core/models/update_virtual_circuit_details.rb +0 -240
  94. data/lib/oraclebmc/core/models/update_vnic_details.rb +0 -144
  95. data/lib/oraclebmc/core/models/update_volume_backup_details.rb +0 -122
  96. data/lib/oraclebmc/core/models/update_volume_details.rb +0 -122
  97. data/lib/oraclebmc/core/models/vcn.rb +0 -276
  98. data/lib/oraclebmc/core/models/virtual_circuit.rb +0 -395
  99. data/lib/oraclebmc/core/models/virtual_circuit_bandwidth_shape.rb +0 -137
  100. data/lib/oraclebmc/core/models/vnic.rb +0 -287
  101. data/lib/oraclebmc/core/models/vnic_attachment.rb +0 -250
  102. data/lib/oraclebmc/core/models/volume.rb +0 -210
  103. data/lib/oraclebmc/core/models/volume_attachment.rb +0 -246
  104. data/lib/oraclebmc/core/models/volume_backup.rb +0 -235
  105. data/lib/oraclebmc/core/util.rb +0 -1
  106. data/lib/oraclebmc/core/virtual_network_client.rb +0 -3419
  107. data/lib/oraclebmc/errors.rb +0 -80
  108. data/lib/oraclebmc/global_context.rb +0 -21
  109. data/lib/oraclebmc/identity/identity.rb +0 -51
  110. data/lib/oraclebmc/identity/identity_client.rb +0 -1983
  111. data/lib/oraclebmc/identity/models/add_user_to_group_details.rb +0 -131
  112. data/lib/oraclebmc/identity/models/api_key.rb +0 -211
  113. data/lib/oraclebmc/identity/models/availability_domain.rb +0 -131
  114. data/lib/oraclebmc/identity/models/compartment.rb +0 -211
  115. data/lib/oraclebmc/identity/models/create_api_key_details.rb +0 -120
  116. data/lib/oraclebmc/identity/models/create_compartment_details.rb +0 -145
  117. data/lib/oraclebmc/identity/models/create_group_details.rb +0 -144
  118. data/lib/oraclebmc/identity/models/create_identity_provider_details.rb +0 -212
  119. data/lib/oraclebmc/identity/models/create_idp_group_mapping_details.rb +0 -133
  120. data/lib/oraclebmc/identity/models/create_policy_details.rb +0 -173
  121. data/lib/oraclebmc/identity/models/create_region_subscription_details.rb +0 -127
  122. data/lib/oraclebmc/identity/models/create_saml2_identity_provider_details.rb +0 -154
  123. data/lib/oraclebmc/identity/models/create_swift_password_details.rb +0 -121
  124. data/lib/oraclebmc/identity/models/create_user_details.rb +0 -144
  125. data/lib/oraclebmc/identity/models/group.rb +0 -211
  126. data/lib/oraclebmc/identity/models/identity_provider.rb +0 -256
  127. data/lib/oraclebmc/identity/models/idp_group_mapping.rb +0 -220
  128. data/lib/oraclebmc/identity/models/policy.rb +0 -237
  129. data/lib/oraclebmc/identity/models/region.rb +0 -141
  130. data/lib/oraclebmc/identity/models/region_subscription.rb +0 -178
  131. data/lib/oraclebmc/identity/models/saml2_identity_provider.rb +0 -180
  132. data/lib/oraclebmc/identity/models/swift_password.rb +0 -226
  133. data/lib/oraclebmc/identity/models/tenancy.rb +0 -158
  134. data/lib/oraclebmc/identity/models/ui_password.rb +0 -187
  135. data/lib/oraclebmc/identity/models/update_compartment_details.rb +0 -120
  136. data/lib/oraclebmc/identity/models/update_group_details.rb +0 -120
  137. data/lib/oraclebmc/identity/models/update_identity_provider_details.rb +0 -160
  138. data/lib/oraclebmc/identity/models/update_idp_group_mapping_details.rb +0 -131
  139. data/lib/oraclebmc/identity/models/update_policy_details.rb +0 -148
  140. data/lib/oraclebmc/identity/models/update_saml2_identity_provider_details.rb +0 -145
  141. data/lib/oraclebmc/identity/models/update_state_details.rb +0 -121
  142. data/lib/oraclebmc/identity/models/update_swift_password_details.rb +0 -120
  143. data/lib/oraclebmc/identity/models/update_user_details.rb +0 -120
  144. data/lib/oraclebmc/identity/models/user.rb +0 -217
  145. data/lib/oraclebmc/identity/models/user_group_membership.rb +0 -209
  146. data/lib/oraclebmc/identity/util.rb +0 -1
  147. data/lib/oraclebmc/internal/internal.rb +0 -11
  148. data/lib/oraclebmc/internal/util.rb +0 -69
  149. data/lib/oraclebmc/load_balancer/load_balancer.rb +0 -46
  150. data/lib/oraclebmc/load_balancer/load_balancer_client.rb +0 -1281
  151. data/lib/oraclebmc/load_balancer/models/backend.rb +0 -220
  152. data/lib/oraclebmc/load_balancer/models/backend_details.rb +0 -206
  153. data/lib/oraclebmc/load_balancer/models/backend_set.rb +0 -179
  154. data/lib/oraclebmc/load_balancer/models/backend_set_details.rb +0 -165
  155. data/lib/oraclebmc/load_balancer/models/certificate.rb +0 -167
  156. data/lib/oraclebmc/load_balancer/models/certificate_details.rb +0 -203
  157. data/lib/oraclebmc/load_balancer/models/create_backend_details.rb +0 -206
  158. data/lib/oraclebmc/load_balancer/models/create_backend_set_details.rb +0 -178
  159. data/lib/oraclebmc/load_balancer/models/create_certificate_details.rb +0 -203
  160. data/lib/oraclebmc/load_balancer/models/create_listener_details.rb +0 -174
  161. data/lib/oraclebmc/load_balancer/models/create_load_balancer_details.rb +0 -219
  162. data/lib/oraclebmc/load_balancer/models/health_checker.rb +0 -223
  163. data/lib/oraclebmc/load_balancer/models/health_checker_details.rb +0 -222
  164. data/lib/oraclebmc/load_balancer/models/ip_address.rb +0 -139
  165. data/lib/oraclebmc/load_balancer/models/listener.rb +0 -174
  166. data/lib/oraclebmc/load_balancer/models/listener_details.rb +0 -160
  167. data/lib/oraclebmc/load_balancer/models/load_balancer.rb +0 -280
  168. data/lib/oraclebmc/load_balancer/models/load_balancer_policy.rb +0 -120
  169. data/lib/oraclebmc/load_balancer/models/load_balancer_protocol.rb +0 -120
  170. data/lib/oraclebmc/load_balancer/models/load_balancer_shape.rb +0 -120
  171. data/lib/oraclebmc/load_balancer/models/session_persistence_configuration_details.rb +0 -141
  172. data/lib/oraclebmc/load_balancer/models/ssl_configuration.rb +0 -153
  173. data/lib/oraclebmc/load_balancer/models/ssl_configuration_details.rb +0 -153
  174. data/lib/oraclebmc/load_balancer/models/update_backend_details.rb +0 -178
  175. data/lib/oraclebmc/load_balancer/models/update_backend_set_details.rb +0 -165
  176. data/lib/oraclebmc/load_balancer/models/update_health_checker_details.rb +0 -221
  177. data/lib/oraclebmc/load_balancer/models/update_listener_details.rb +0 -160
  178. data/lib/oraclebmc/load_balancer/models/update_load_balancer_details.rb +0 -123
  179. data/lib/oraclebmc/load_balancer/models/work_request.rb +0 -229
  180. data/lib/oraclebmc/load_balancer/models/work_request_error.rb +0 -145
  181. data/lib/oraclebmc/load_balancer/util.rb +0 -55
  182. data/lib/oraclebmc/regions.rb +0 -41
  183. data/lib/oraclebmc/response.rb +0 -86
  184. data/lib/oraclebmc/signer.rb +0 -119
  185. data/lib/oraclebmc/version.rb +0 -5
  186. data/lib/oraclebmc/waiter.rb +0 -111
@@ -1,160 +0,0 @@
1
- # Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved.
2
-
3
- require 'date'
4
-
5
- module OracleBMC
6
- class LoadBalancer::Models::ListenerDetails
7
- # The name of the associated backend set.
8
- # @return [String]
9
- attr_accessor :default_backend_set_name
10
-
11
- # The communication port for the listener.
12
- #
13
- # Example: `80`
14
- #
15
- # @return [Integer]
16
- attr_accessor :port
17
-
18
- # The protocol on which the listener accepts connection requests.
19
- # To get a list of valid protocols, use the {#list_protocols list_protocols}
20
- # operation.
21
- #
22
- # Example: `HTTP`
23
- #
24
- # @return [String]
25
- attr_accessor :protocol
26
-
27
- # @return [OracleBMC::LoadBalancer::Models::SSLConfigurationDetails]
28
- attr_accessor :ssl_configuration
29
-
30
-
31
- # Initializes the object
32
- # @param [Hash] attributes Model attributes in the form of hash
33
- def initialize(attributes = {})
34
- return unless attributes.is_a?(Hash)
35
-
36
- # convert string to symbol for hash key
37
- attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
38
-
39
- if attributes[:'defaultBackendSetName']
40
- self.default_backend_set_name = attributes[:'defaultBackendSetName']
41
- end
42
-
43
- if attributes[:'port']
44
- self.port = attributes[:'port']
45
- end
46
-
47
- if attributes[:'protocol']
48
- self.protocol = attributes[:'protocol']
49
- end
50
-
51
- if attributes[:'sslConfiguration']
52
- self.ssl_configuration = attributes[:'sslConfiguration']
53
- end
54
-
55
- end
56
-
57
- # Checks equality by comparing each attribute.
58
- # @param [Object] other_object to be compared
59
- def ==(other_object)
60
- return true if self.equal?(other_object)
61
- self.class == other_object.class &&
62
- default_backend_set_name == other_object.default_backend_set_name &&
63
- port == other_object.port &&
64
- protocol == other_object.protocol &&
65
- ssl_configuration == other_object.ssl_configuration
66
- end
67
-
68
- # @see the `==` method
69
- # @param [Object] other_object to be compared
70
- def eql?(other_object)
71
- self == other_object
72
- end
73
-
74
- # Calculates hash code according to all attributes.
75
- # @return [Fixnum] Hash code
76
- def hash
77
- [default_backend_set_name, port, protocol, ssl_configuration].hash
78
- end
79
-
80
- # Builds the object from hash
81
- # @param [Hash] attributes Model attributes in the form of hash
82
- # @return [Object] Returns the model itself
83
- def build_from_hash(attributes)
84
- return nil unless attributes.is_a?(Hash)
85
- self.class.swagger_types.each_pair do |key, type|
86
- if type =~ /^Array<(.*)>/i
87
- # check to ensure the input is an array given that the the attribute
88
- # is documented as an array but the input is not
89
- if attributes[self.class.attribute_map[key]].is_a?(Array)
90
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| OracleBMC::Internal::Util.convert_to_type($1, v) } )
91
- end
92
- elsif !attributes[self.class.attribute_map[key]].nil?
93
- self.send("#{key}=", OracleBMC::Internal::Util.convert_to_type(type, attributes[self.class.attribute_map[key]]))
94
- end # or else data not found in attributes(hash), not an issue as the data can be optional
95
- end
96
-
97
- self
98
- end
99
-
100
- # Returns the string representation of the object
101
- # @return [String] String presentation of the object
102
- def to_s
103
- to_hash.to_s
104
- end
105
-
106
- # Returns the object in the form of hash
107
- # @return [Hash] Returns the object in the form of hash
108
- def to_hash
109
- hash = {}
110
- self.class.attribute_map.each_pair do |attr, param|
111
- value = self.send(attr)
112
- next if value.nil?
113
- hash[param] = _to_hash(value)
114
- end
115
- hash
116
- end
117
-
118
- private
119
-
120
- # Outputs non-array value in the form of hash
121
- # For object, use to_hash. Otherwise, just return the value
122
- # @param [Object] value Any valid value
123
- # @return [Hash] Returns the value in the form of hash
124
- def _to_hash(value)
125
- if value.is_a?(Array)
126
- value.compact.map{ |v| _to_hash(v) }
127
- elsif value.is_a?(Hash)
128
- {}.tap do |hash|
129
- value.each { |k, v| hash[k] = _to_hash(v) }
130
- end
131
- elsif value.respond_to? :to_hash
132
- value.to_hash
133
- else
134
- value
135
- end
136
- end
137
-
138
-
139
-
140
- # Attribute mapping from ruby-style variable name to JSON key.
141
- def self.attribute_map
142
- {
143
- :'default_backend_set_name' => :'defaultBackendSetName',
144
- :'port' => :'port',
145
- :'protocol' => :'protocol',
146
- :'ssl_configuration' => :'sslConfiguration'
147
- }
148
- end
149
-
150
- # Attribute type mapping.
151
- def self.swagger_types
152
- {
153
- :'default_backend_set_name' => :'String',
154
- :'port' => :'Integer',
155
- :'protocol' => :'String',
156
- :'ssl_configuration' => :'OracleBMC::LoadBalancer::Models::SSLConfigurationDetails'
157
- }
158
- end
159
- end
160
- end
@@ -1,280 +0,0 @@
1
- # Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved.
2
-
3
- require 'date'
4
-
5
- module OracleBMC
6
- class LoadBalancer::Models::LoadBalancer
7
-
8
- LIFECYCLE_STATE_ENUM = [LIFECYCLE_STATE_CREATING = 'CREATING',
9
- LIFECYCLE_STATE_FAILED = 'FAILED',
10
- LIFECYCLE_STATE_ACTIVE = 'ACTIVE',
11
- LIFECYCLE_STATE_DELETING = 'DELETING',
12
- LIFECYCLE_STATE_DELETED = 'DELETED',
13
- LIFECYCLE_STATE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE']
14
-
15
- # @return [Hash<String, OracleBMC::LoadBalancer::Models::BackendSet>]
16
- attr_accessor :backend_sets
17
-
18
- # @return [Hash<String, OracleBMC::LoadBalancer::Models::Certificate>]
19
- attr_accessor :certificates
20
-
21
- # The [OCID](https://docs.us-phoenix-1.oraclecloud.com/Content/General/Concepts/identifiers.htm) of the compartment containing the load balancer.
22
- # @return [String]
23
- attr_accessor :compartment_id
24
-
25
- # A user-friendly name. It does not have to be unique, and it is changeable.
26
- #
27
- # Example: `My load balancer`
28
- #
29
- # @return [String]
30
- attr_accessor :display_name
31
-
32
- # The [OCID](https://docs.us-phoenix-1.oraclecloud.com/Content/General/Concepts/identifiers.htm) of the load balancer.
33
- # @return [String]
34
- attr_accessor :id
35
-
36
- # An array of IP addresses.
37
- #
38
- # @return [Array<OracleBMC::LoadBalancer::Models::IpAddress>]
39
- attr_accessor :ip_addresses
40
-
41
- # Whether the load balancer has a VCN-local (private) IP address.
42
- #
43
- # If \"true\", the service assigns a private IP address to the load balancer. The load balancer requires only one subnet
44
- # to host both the primary and secondary load balancers. The private IP address is local to the subnet. The load balancer
45
- # is accessible only from within the VCN that contains the associated subnet, or as further restricted by your security
46
- # list rules. The load balancer can route traffic to any backend server that is reachable from the VCN.
47
- #
48
- # For a private load balancer, both the primary and secondary load balancer hosts are within the same Availability Domain.
49
- #
50
- # If \"false\", the service assigns a public IP address to the load balancer. A load balancer with a public IP address
51
- # requires two subnets, each in a different Availability Domain. One subnet hosts the primary load balancer and the other
52
- # hosts the secondary (stand-by) load balancer. A public load balancer is accessible from the internet, depending on your
53
- # VCN's [security list rules](https://docs.us-phoenix-1.oraclecloud.com/Content/Network/Concepts/securitylists.htm).
54
- #
55
- # @return [BOOLEAN]
56
- attr_accessor :is_private
57
-
58
- # @return [String]
59
- attr_accessor :lifecycle_state
60
-
61
- # @return [Hash<String, OracleBMC::LoadBalancer::Models::Listener>]
62
- attr_accessor :listeners
63
-
64
- # A template that determines the total pre-provisioned bandwidth (ingress plus egress).
65
- # To get a list of available shapes, use the {#list_shapes list_shapes}
66
- # operation.
67
- #
68
- # Example: `100Mbps`
69
- #
70
- # @return [String]
71
- attr_accessor :shape_name
72
-
73
- # An array of subnet [OCIDs](https://docs.us-phoenix-1.oraclecloud.com/Content/General/Concepts/identifiers.htm).
74
- # @return [Array<String>]
75
- attr_accessor :subnet_ids
76
-
77
- # The date and time the load balancer was created, in the format defined by RFC3339.
78
- #
79
- # Example: `2016-08-25T21:10:29.600Z`
80
- #
81
- # @return [DateTime]
82
- attr_accessor :time_created
83
-
84
-
85
- # Initializes the object
86
- # @param [Hash] attributes Model attributes in the form of hash
87
- def initialize(attributes = {})
88
- return unless attributes.is_a?(Hash)
89
-
90
- # convert string to symbol for hash key
91
- attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
92
-
93
- if attributes[:'backendSets']
94
- self.backend_sets = attributes[:'backendSets']
95
- end
96
-
97
- if attributes[:'certificates']
98
- self.certificates = attributes[:'certificates']
99
- end
100
-
101
- if attributes[:'compartmentId']
102
- self.compartment_id = attributes[:'compartmentId']
103
- end
104
-
105
- if attributes[:'displayName']
106
- self.display_name = attributes[:'displayName']
107
- end
108
-
109
- if attributes[:'id']
110
- self.id = attributes[:'id']
111
- end
112
-
113
- if attributes[:'ipAddresses']
114
- self.ip_addresses = attributes[:'ipAddresses']
115
- end
116
-
117
- if attributes[:'isPrivate']
118
- self.is_private = attributes[:'isPrivate']
119
- end
120
-
121
- if attributes[:'lifecycleState']
122
- self.lifecycle_state = attributes[:'lifecycleState']
123
- end
124
-
125
- if attributes[:'listeners']
126
- self.listeners = attributes[:'listeners']
127
- end
128
-
129
- if attributes[:'shapeName']
130
- self.shape_name = attributes[:'shapeName']
131
- end
132
-
133
- if attributes[:'subnetIds']
134
- self.subnet_ids = attributes[:'subnetIds']
135
- end
136
-
137
- if attributes[:'timeCreated']
138
- self.time_created = attributes[:'timeCreated']
139
- end
140
-
141
- end
142
-
143
- # Custom attribute writer method checking allowed values (enum).
144
- # @param [Object] lifecycle_state Object to be assigned
145
- def lifecycle_state=(lifecycle_state)
146
- if lifecycle_state && !LIFECYCLE_STATE_ENUM.include?(lifecycle_state)
147
- @lifecycle_state = LIFECYCLE_STATE_UNKNOWN_ENUM_VALUE
148
- else
149
- @lifecycle_state = lifecycle_state
150
- end
151
- end
152
-
153
- # Checks equality by comparing each attribute.
154
- # @param [Object] other_object to be compared
155
- def ==(other_object)
156
- return true if self.equal?(other_object)
157
- self.class == other_object.class &&
158
- backend_sets == other_object.backend_sets &&
159
- certificates == other_object.certificates &&
160
- compartment_id == other_object.compartment_id &&
161
- display_name == other_object.display_name &&
162
- id == other_object.id &&
163
- ip_addresses == other_object.ip_addresses &&
164
- is_private == other_object.is_private &&
165
- lifecycle_state == other_object.lifecycle_state &&
166
- listeners == other_object.listeners &&
167
- shape_name == other_object.shape_name &&
168
- subnet_ids == other_object.subnet_ids &&
169
- time_created == other_object.time_created
170
- end
171
-
172
- # @see the `==` method
173
- # @param [Object] other_object to be compared
174
- def eql?(other_object)
175
- self == other_object
176
- end
177
-
178
- # Calculates hash code according to all attributes.
179
- # @return [Fixnum] Hash code
180
- def hash
181
- [backend_sets, certificates, compartment_id, display_name, id, ip_addresses, is_private, lifecycle_state, listeners, shape_name, subnet_ids, time_created].hash
182
- end
183
-
184
- # Builds the object from hash
185
- # @param [Hash] attributes Model attributes in the form of hash
186
- # @return [Object] Returns the model itself
187
- def build_from_hash(attributes)
188
- return nil unless attributes.is_a?(Hash)
189
- self.class.swagger_types.each_pair do |key, type|
190
- if type =~ /^Array<(.*)>/i
191
- # check to ensure the input is an array given that the the attribute
192
- # is documented as an array but the input is not
193
- if attributes[self.class.attribute_map[key]].is_a?(Array)
194
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| OracleBMC::Internal::Util.convert_to_type($1, v) } )
195
- end
196
- elsif !attributes[self.class.attribute_map[key]].nil?
197
- self.send("#{key}=", OracleBMC::Internal::Util.convert_to_type(type, attributes[self.class.attribute_map[key]]))
198
- end # or else data not found in attributes(hash), not an issue as the data can be optional
199
- end
200
-
201
- self
202
- end
203
-
204
- # Returns the string representation of the object
205
- # @return [String] String presentation of the object
206
- def to_s
207
- to_hash.to_s
208
- end
209
-
210
- # Returns the object in the form of hash
211
- # @return [Hash] Returns the object in the form of hash
212
- def to_hash
213
- hash = {}
214
- self.class.attribute_map.each_pair do |attr, param|
215
- value = self.send(attr)
216
- next if value.nil?
217
- hash[param] = _to_hash(value)
218
- end
219
- hash
220
- end
221
-
222
- private
223
-
224
- # Outputs non-array value in the form of hash
225
- # For object, use to_hash. Otherwise, just return the value
226
- # @param [Object] value Any valid value
227
- # @return [Hash] Returns the value in the form of hash
228
- def _to_hash(value)
229
- if value.is_a?(Array)
230
- value.compact.map{ |v| _to_hash(v) }
231
- elsif value.is_a?(Hash)
232
- {}.tap do |hash|
233
- value.each { |k, v| hash[k] = _to_hash(v) }
234
- end
235
- elsif value.respond_to? :to_hash
236
- value.to_hash
237
- else
238
- value
239
- end
240
- end
241
-
242
-
243
-
244
- # Attribute mapping from ruby-style variable name to JSON key.
245
- def self.attribute_map
246
- {
247
- :'backend_sets' => :'backendSets',
248
- :'certificates' => :'certificates',
249
- :'compartment_id' => :'compartmentId',
250
- :'display_name' => :'displayName',
251
- :'id' => :'id',
252
- :'ip_addresses' => :'ipAddresses',
253
- :'is_private' => :'isPrivate',
254
- :'lifecycle_state' => :'lifecycleState',
255
- :'listeners' => :'listeners',
256
- :'shape_name' => :'shapeName',
257
- :'subnet_ids' => :'subnetIds',
258
- :'time_created' => :'timeCreated'
259
- }
260
- end
261
-
262
- # Attribute type mapping.
263
- def self.swagger_types
264
- {
265
- :'backend_sets' => :'Hash<String, OracleBMC::LoadBalancer::Models::BackendSet>',
266
- :'certificates' => :'Hash<String, OracleBMC::LoadBalancer::Models::Certificate>',
267
- :'compartment_id' => :'String',
268
- :'display_name' => :'String',
269
- :'id' => :'String',
270
- :'ip_addresses' => :'Array<OracleBMC::LoadBalancer::Models::IpAddress>',
271
- :'is_private' => :'BOOLEAN',
272
- :'lifecycle_state' => :'String',
273
- :'listeners' => :'Hash<String, OracleBMC::LoadBalancer::Models::Listener>',
274
- :'shape_name' => :'String',
275
- :'subnet_ids' => :'Array<String>',
276
- :'time_created' => :'DateTime'
277
- }
278
- end
279
- end
280
- end
@@ -1,120 +0,0 @@
1
- # Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved.
2
-
3
- require 'date'
4
-
5
- module OracleBMC
6
- class LoadBalancer::Models::LoadBalancerPolicy
7
- # The name of the load balancing policy.
8
- # @return [String]
9
- attr_accessor :name
10
-
11
-
12
- # Initializes the object
13
- # @param [Hash] attributes Model attributes in the form of hash
14
- def initialize(attributes = {})
15
- return unless attributes.is_a?(Hash)
16
-
17
- # convert string to symbol for hash key
18
- attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
19
-
20
- if attributes[:'name']
21
- self.name = attributes[:'name']
22
- end
23
-
24
- end
25
-
26
- # Checks equality by comparing each attribute.
27
- # @param [Object] other_object to be compared
28
- def ==(other_object)
29
- return true if self.equal?(other_object)
30
- self.class == other_object.class &&
31
- name == other_object.name
32
- end
33
-
34
- # @see the `==` method
35
- # @param [Object] other_object to be compared
36
- def eql?(other_object)
37
- self == other_object
38
- end
39
-
40
- # Calculates hash code according to all attributes.
41
- # @return [Fixnum] Hash code
42
- def hash
43
- [name].hash
44
- end
45
-
46
- # Builds the object from hash
47
- # @param [Hash] attributes Model attributes in the form of hash
48
- # @return [Object] Returns the model itself
49
- def build_from_hash(attributes)
50
- return nil unless attributes.is_a?(Hash)
51
- self.class.swagger_types.each_pair do |key, type|
52
- if type =~ /^Array<(.*)>/i
53
- # check to ensure the input is an array given that the the attribute
54
- # is documented as an array but the input is not
55
- if attributes[self.class.attribute_map[key]].is_a?(Array)
56
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| OracleBMC::Internal::Util.convert_to_type($1, v) } )
57
- end
58
- elsif !attributes[self.class.attribute_map[key]].nil?
59
- self.send("#{key}=", OracleBMC::Internal::Util.convert_to_type(type, attributes[self.class.attribute_map[key]]))
60
- end # or else data not found in attributes(hash), not an issue as the data can be optional
61
- end
62
-
63
- self
64
- end
65
-
66
- # Returns the string representation of the object
67
- # @return [String] String presentation of the object
68
- def to_s
69
- to_hash.to_s
70
- end
71
-
72
- # Returns the object in the form of hash
73
- # @return [Hash] Returns the object in the form of hash
74
- def to_hash
75
- hash = {}
76
- self.class.attribute_map.each_pair do |attr, param|
77
- value = self.send(attr)
78
- next if value.nil?
79
- hash[param] = _to_hash(value)
80
- end
81
- hash
82
- end
83
-
84
- private
85
-
86
- # Outputs non-array value in the form of hash
87
- # For object, use to_hash. Otherwise, just return the value
88
- # @param [Object] value Any valid value
89
- # @return [Hash] Returns the value in the form of hash
90
- def _to_hash(value)
91
- if value.is_a?(Array)
92
- value.compact.map{ |v| _to_hash(v) }
93
- elsif value.is_a?(Hash)
94
- {}.tap do |hash|
95
- value.each { |k, v| hash[k] = _to_hash(v) }
96
- end
97
- elsif value.respond_to? :to_hash
98
- value.to_hash
99
- else
100
- value
101
- end
102
- end
103
-
104
-
105
-
106
- # Attribute mapping from ruby-style variable name to JSON key.
107
- def self.attribute_map
108
- {
109
- :'name' => :'name'
110
- }
111
- end
112
-
113
- # Attribute type mapping.
114
- def self.swagger_types
115
- {
116
- :'name' => :'String'
117
- }
118
- end
119
- end
120
- end