topological_inventory-api-client 1.0.0 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (183) hide show
  1. checksums.yaml +4 -4
  2. data/docs/DefaultApi.md +1444 -1
  3. data/docs/ServiceInstance.md +2 -0
  4. data/docs/ServiceInstanceNode.md +2 -0
  5. data/docs/ServiceOffering.md +2 -0
  6. data/docs/ServiceOfferingNode.md +2 -0
  7. data/docs/Tag.md +2 -14
  8. data/docs/Vm.md +2 -0
  9. data/lib/topological_inventory-api-client.rb +1 -2
  10. data/lib/topological_inventory-api-client/api/default_api.rb +1925 -1
  11. data/lib/topological_inventory-api-client/api_client.rb +1 -1
  12. data/lib/topological_inventory-api-client/api_error.rb +1 -1
  13. data/lib/topological_inventory-api-client/configuration.rb +4 -4
  14. data/lib/topological_inventory-api-client/models/applied_inventories_parameters_service_plan.rb +1 -1
  15. data/lib/topological_inventory-api-client/models/availabilities_collection.rb +1 -1
  16. data/lib/topological_inventory-api-client/models/availability.rb +1 -1
  17. data/lib/topological_inventory-api-client/models/cluster.rb +1 -1
  18. data/lib/topological_inventory-api-client/models/clusters_collection.rb +1 -1
  19. data/lib/topological_inventory-api-client/models/collection_links.rb +1 -1
  20. data/lib/topological_inventory-api-client/models/collection_metadata.rb +1 -1
  21. data/lib/topological_inventory-api-client/models/container.rb +1 -1
  22. data/lib/topological_inventory-api-client/models/container_group.rb +1 -1
  23. data/lib/topological_inventory-api-client/models/container_groups_collection.rb +1 -1
  24. data/lib/topological_inventory-api-client/models/container_image.rb +1 -1
  25. data/lib/topological_inventory-api-client/models/container_images_collection.rb +1 -1
  26. data/lib/topological_inventory-api-client/models/container_node.rb +1 -1
  27. data/lib/topological_inventory-api-client/models/container_nodes_collection.rb +1 -1
  28. data/lib/topological_inventory-api-client/models/container_project.rb +1 -1
  29. data/lib/topological_inventory-api-client/models/container_projects_collection.rb +1 -1
  30. data/lib/topological_inventory-api-client/models/container_resource_quota.rb +1 -1
  31. data/lib/topological_inventory-api-client/models/container_resource_quota_collection.rb +1 -1
  32. data/lib/topological_inventory-api-client/models/container_template.rb +1 -1
  33. data/lib/topological_inventory-api-client/models/container_templates_collection.rb +1 -1
  34. data/lib/topological_inventory-api-client/models/containers_collection.rb +1 -1
  35. data/lib/topological_inventory-api-client/models/datastore.rb +1 -1
  36. data/lib/topological_inventory-api-client/models/datastores_collection.rb +1 -1
  37. data/lib/topological_inventory-api-client/models/error_not_found.rb +1 -1
  38. data/lib/topological_inventory-api-client/models/error_not_found_errors.rb +1 -1
  39. data/lib/topological_inventory-api-client/models/flavor.rb +1 -1
  40. data/lib/topological_inventory-api-client/models/flavors_collection.rb +1 -1
  41. data/lib/topological_inventory-api-client/models/graph_ql_request.rb +1 -1
  42. data/lib/topological_inventory-api-client/models/graph_ql_response.rb +1 -1
  43. data/lib/topological_inventory-api-client/models/host.rb +1 -1
  44. data/lib/topological_inventory-api-client/models/hosts_collection.rb +1 -1
  45. data/lib/topological_inventory-api-client/models/inline_response200.rb +1 -1
  46. data/lib/topological_inventory-api-client/models/ipaddress.rb +1 -1
  47. data/lib/topological_inventory-api-client/models/ipaddresses_collection.rb +1 -1
  48. data/lib/topological_inventory-api-client/models/network.rb +1 -1
  49. data/lib/topological_inventory-api-client/models/network_adapter.rb +1 -1
  50. data/lib/topological_inventory-api-client/models/network_adapters_collection.rb +1 -1
  51. data/lib/topological_inventory-api-client/models/networks_collection.rb +1 -1
  52. data/lib/topological_inventory-api-client/models/orchestration_stack.rb +1 -1
  53. data/lib/topological_inventory-api-client/models/orchestration_stacks_collection.rb +1 -1
  54. data/lib/topological_inventory-api-client/models/order_parameters_service_offering.rb +1 -1
  55. data/lib/topological_inventory-api-client/models/order_parameters_service_plan.rb +1 -1
  56. data/lib/topological_inventory-api-client/models/security_group.rb +1 -1
  57. data/lib/topological_inventory-api-client/models/security_groups_collection.rb +1 -1
  58. data/lib/topological_inventory-api-client/models/service_instance.rb +29 -2
  59. data/lib/topological_inventory-api-client/models/service_instance_node.rb +29 -2
  60. data/lib/topological_inventory-api-client/models/service_instance_nodes_collection.rb +1 -1
  61. data/lib/topological_inventory-api-client/models/service_instances_collection.rb +1 -1
  62. data/lib/topological_inventory-api-client/models/service_inventories_collection.rb +1 -1
  63. data/lib/topological_inventory-api-client/models/service_inventory.rb +1 -1
  64. data/lib/topological_inventory-api-client/models/service_offering.rb +29 -2
  65. data/lib/topological_inventory-api-client/models/service_offering_icon.rb +1 -1
  66. data/lib/topological_inventory-api-client/models/service_offering_icons_collection.rb +1 -1
  67. data/lib/topological_inventory-api-client/models/service_offering_node.rb +29 -2
  68. data/lib/topological_inventory-api-client/models/service_offering_nodes_collection.rb +1 -1
  69. data/lib/topological_inventory-api-client/models/service_offerings_collection.rb +1 -1
  70. data/lib/topological_inventory-api-client/models/service_plan.rb +1 -1
  71. data/lib/topological_inventory-api-client/models/service_plans_collection.rb +1 -1
  72. data/lib/topological_inventory-api-client/models/source.rb +1 -1
  73. data/lib/topological_inventory-api-client/models/source_region.rb +1 -1
  74. data/lib/topological_inventory-api-client/models/source_regions_collection.rb +1 -1
  75. data/lib/topological_inventory-api-client/models/sources_collection.rb +1 -1
  76. data/lib/topological_inventory-api-client/models/subnet.rb +1 -1
  77. data/lib/topological_inventory-api-client/models/subnets_collection.rb +1 -1
  78. data/lib/topological_inventory-api-client/models/subscription.rb +1 -1
  79. data/lib/topological_inventory-api-client/models/subscriptions_collection.rb +1 -1
  80. data/lib/topological_inventory-api-client/models/tag.rb +8 -80
  81. data/lib/topological_inventory-api-client/models/tags_collection.rb +1 -1
  82. data/lib/topological_inventory-api-client/models/task.rb +1 -1
  83. data/lib/topological_inventory-api-client/models/tasks_collection.rb +1 -1
  84. data/lib/topological_inventory-api-client/models/tenant.rb +1 -1
  85. data/lib/topological_inventory-api-client/models/vm.rb +29 -2
  86. data/lib/topological_inventory-api-client/models/vms_collection.rb +1 -1
  87. data/lib/topological_inventory-api-client/models/volume.rb +1 -1
  88. data/lib/topological_inventory-api-client/models/volume_attachment.rb +1 -1
  89. data/lib/topological_inventory-api-client/models/volume_attachments_collection.rb +1 -1
  90. data/lib/topological_inventory-api-client/models/volume_type.rb +1 -1
  91. data/lib/topological_inventory-api-client/models/volume_types_collection.rb +1 -1
  92. data/lib/topological_inventory-api-client/models/volumes_collection.rb +1 -1
  93. data/lib/topological_inventory-api-client/version.rb +2 -2
  94. data/spec/api/default_api_spec.rb +339 -1
  95. data/spec/api_client_spec.rb +1 -1
  96. data/spec/configuration_spec.rb +4 -4
  97. data/spec/models/applied_inventories_parameters_service_plan_spec.rb +1 -1
  98. data/spec/models/availabilities_collection_spec.rb +1 -1
  99. data/spec/models/availability_spec.rb +1 -1
  100. data/spec/models/cluster_spec.rb +1 -1
  101. data/spec/models/clusters_collection_spec.rb +1 -1
  102. data/spec/models/collection_links_spec.rb +1 -1
  103. data/spec/models/collection_metadata_spec.rb +1 -1
  104. data/spec/models/container_group_spec.rb +1 -1
  105. data/spec/models/container_groups_collection_spec.rb +1 -1
  106. data/spec/models/container_image_spec.rb +1 -1
  107. data/spec/models/container_images_collection_spec.rb +1 -1
  108. data/spec/models/container_node_spec.rb +1 -1
  109. data/spec/models/container_nodes_collection_spec.rb +1 -1
  110. data/spec/models/container_project_spec.rb +1 -1
  111. data/spec/models/container_projects_collection_spec.rb +1 -1
  112. data/spec/models/container_resource_quota_collection_spec.rb +1 -1
  113. data/spec/models/container_resource_quota_spec.rb +1 -1
  114. data/spec/models/container_spec.rb +1 -1
  115. data/spec/models/container_template_spec.rb +1 -1
  116. data/spec/models/container_templates_collection_spec.rb +1 -1
  117. data/spec/models/containers_collection_spec.rb +1 -1
  118. data/spec/models/datastore_spec.rb +1 -1
  119. data/spec/models/datastores_collection_spec.rb +1 -1
  120. data/spec/models/error_not_found_errors_spec.rb +1 -1
  121. data/spec/models/error_not_found_spec.rb +1 -1
  122. data/spec/models/flavor_spec.rb +1 -1
  123. data/spec/models/flavors_collection_spec.rb +1 -1
  124. data/spec/models/graph_ql_request_spec.rb +1 -1
  125. data/spec/models/graph_ql_response_spec.rb +1 -1
  126. data/spec/models/host_spec.rb +1 -1
  127. data/spec/models/hosts_collection_spec.rb +1 -1
  128. data/spec/models/inline_response200_spec.rb +1 -1
  129. data/spec/models/ipaddress_spec.rb +1 -1
  130. data/spec/models/ipaddresses_collection_spec.rb +1 -1
  131. data/spec/models/network_adapter_spec.rb +1 -1
  132. data/spec/models/network_adapters_collection_spec.rb +1 -1
  133. data/spec/models/network_spec.rb +1 -1
  134. data/spec/models/networks_collection_spec.rb +1 -1
  135. data/spec/models/orchestration_stack_spec.rb +1 -1
  136. data/spec/models/orchestration_stacks_collection_spec.rb +1 -1
  137. data/spec/models/order_parameters_service_offering_spec.rb +1 -1
  138. data/spec/models/order_parameters_service_plan_spec.rb +1 -1
  139. data/spec/models/security_group_spec.rb +1 -1
  140. data/spec/models/security_groups_collection_spec.rb +1 -1
  141. data/spec/models/service_instance_node_spec.rb +7 -1
  142. data/spec/models/service_instance_nodes_collection_spec.rb +1 -1
  143. data/spec/models/service_instance_spec.rb +7 -1
  144. data/spec/models/service_instances_collection_spec.rb +1 -1
  145. data/spec/models/service_inventories_collection_spec.rb +1 -1
  146. data/spec/models/service_inventory_spec.rb +1 -1
  147. data/spec/models/service_offering_icon_spec.rb +1 -1
  148. data/spec/models/service_offering_icons_collection_spec.rb +1 -1
  149. data/spec/models/service_offering_node_spec.rb +7 -1
  150. data/spec/models/service_offering_nodes_collection_spec.rb +1 -1
  151. data/spec/models/service_offering_spec.rb +7 -1
  152. data/spec/models/service_offerings_collection_spec.rb +1 -1
  153. data/spec/models/service_plan_spec.rb +1 -1
  154. data/spec/models/service_plans_collection_spec.rb +1 -1
  155. data/spec/models/source_region_spec.rb +1 -1
  156. data/spec/models/source_regions_collection_spec.rb +1 -1
  157. data/spec/models/source_spec.rb +1 -1
  158. data/spec/models/sources_collection_spec.rb +1 -1
  159. data/spec/models/subnet_spec.rb +1 -1
  160. data/spec/models/subnets_collection_spec.rb +1 -1
  161. data/spec/models/subscription_spec.rb +1 -1
  162. data/spec/models/subscriptions_collection_spec.rb +1 -1
  163. data/spec/models/tag_spec.rb +2 -38
  164. data/spec/models/tags_collection_spec.rb +1 -1
  165. data/spec/models/task_spec.rb +1 -1
  166. data/spec/models/tasks_collection_spec.rb +1 -1
  167. data/spec/models/tenant_spec.rb +1 -1
  168. data/spec/models/vm_spec.rb +7 -1
  169. data/spec/models/vms_collection_spec.rb +1 -1
  170. data/spec/models/volume_attachment_spec.rb +1 -1
  171. data/spec/models/volume_attachments_collection_spec.rb +1 -1
  172. data/spec/models/volume_spec.rb +1 -1
  173. data/spec/models/volume_type_spec.rb +1 -1
  174. data/spec/models/volume_types_collection_spec.rb +1 -1
  175. data/spec/models/volumes_collection_spec.rb +1 -1
  176. data/spec/spec_helper.rb +1 -1
  177. data/topological_inventory-api-client.gemspec +1 -1
  178. metadata +2 -8
  179. data/docs/Tagging.md +0 -21
  180. data/lib/topological_inventory-api-client/models/tagging.rb +0 -242
  181. data/pkg/topological_inventory-api-client-1.0.0.gem +0 -0
  182. data/spec/models/tagging_spec.rb +0 -53
  183. data/topological_inventory-api-client-2.0.0.gem +0 -0
@@ -5,7 +5,7 @@
5
5
 
6
6
  #Topological Inventory
7
7
 
8
- The version of the OpenAPI document: 1.0.0
8
+ The version of the OpenAPI document: 2.0.0
9
9
  Contact: support@redhat.com
10
10
  Generated by: https://openapi-generator.tech
11
11
  OpenAPI Generator version: 4.2.1
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: topological_inventory-api-client
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 2.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - OpenAPI-Generator
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-01-08 00:00:00.000000000 Z
11
+ date: 2020-01-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: typhoeus
@@ -150,7 +150,6 @@ files:
150
150
  - docs/Subscription.md
151
151
  - docs/SubscriptionsCollection.md
152
152
  - docs/Tag.md
153
- - docs/Tagging.md
154
153
  - docs/TagsCollection.md
155
154
  - docs/Task.md
156
155
  - docs/TasksCollection.md
@@ -236,7 +235,6 @@ files:
236
235
  - lib/topological_inventory-api-client/models/subscription.rb
237
236
  - lib/topological_inventory-api-client/models/subscriptions_collection.rb
238
237
  - lib/topological_inventory-api-client/models/tag.rb
239
- - lib/topological_inventory-api-client/models/tagging.rb
240
238
  - lib/topological_inventory-api-client/models/tags_collection.rb
241
239
  - lib/topological_inventory-api-client/models/task.rb
242
240
  - lib/topological_inventory-api-client/models/tasks_collection.rb
@@ -250,7 +248,6 @@ files:
250
248
  - lib/topological_inventory-api-client/models/volume_types_collection.rb
251
249
  - lib/topological_inventory-api-client/models/volumes_collection.rb
252
250
  - lib/topological_inventory-api-client/version.rb
253
- - pkg/topological_inventory-api-client-1.0.0.gem
254
251
  - spec/api/default_api_spec.rb
255
252
  - spec/api_client_spec.rb
256
253
  - spec/configuration_spec.rb
@@ -321,7 +318,6 @@ files:
321
318
  - spec/models/subscription_spec.rb
322
319
  - spec/models/subscriptions_collection_spec.rb
323
320
  - spec/models/tag_spec.rb
324
- - spec/models/tagging_spec.rb
325
321
  - spec/models/tags_collection_spec.rb
326
322
  - spec/models/task_spec.rb
327
323
  - spec/models/tasks_collection_spec.rb
@@ -335,7 +331,6 @@ files:
335
331
  - spec/models/volume_types_collection_spec.rb
336
332
  - spec/models/volumes_collection_spec.rb
337
333
  - spec/spec_helper.rb
338
- - topological_inventory-api-client-2.0.0.gem
339
334
  - topological_inventory-api-client.gemspec
340
335
  homepage: https://openapi-generator.tech
341
336
  licenses:
@@ -436,7 +431,6 @@ test_files:
436
431
  - spec/models/task_spec.rb
437
432
  - spec/models/container_projects_collection_spec.rb
438
433
  - spec/models/source_regions_collection_spec.rb
439
- - spec/models/tagging_spec.rb
440
434
  - spec/models/service_offerings_collection_spec.rb
441
435
  - spec/models/availability_spec.rb
442
436
  - spec/models/orchestration_stack_spec.rb
data/docs/Tagging.md DELETED
@@ -1,21 +0,0 @@
1
- # TopologicalInventoryApiClient::Tagging
2
-
3
- ## Properties
4
-
5
- Name | Type | Description | Notes
6
- ------------ | ------------- | ------------- | -------------
7
- **tag_id** | **String** | ID of the resource | [optional] [readonly]
8
- **name** | **String** | | [optional] [readonly]
9
- **value** | **String** | | [optional] [readonly]
10
-
11
- ## Code Sample
12
-
13
- ```ruby
14
- require 'TopologicalInventoryApiClient'
15
-
16
- instance = TopologicalInventoryApiClient::Tagging.new(tag_id: null,
17
- name: architecture,
18
- value: x86_64)
19
- ```
20
-
21
-
@@ -1,242 +0,0 @@
1
- =begin
2
- #Topological Inventory
3
-
4
- #Topological Inventory
5
-
6
- The version of the OpenAPI document: 1.0.0
7
- Contact: support@redhat.com
8
- Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 4.2.1
10
-
11
- =end
12
-
13
- require 'date'
14
-
15
- module TopologicalInventoryApiClient
16
- class Tagging
17
- # ID of the resource
18
- attr_accessor :tag_id
19
-
20
- attr_accessor :name
21
-
22
- attr_accessor :value
23
-
24
- # Attribute mapping from ruby-style variable name to JSON key.
25
- def self.attribute_map
26
- {
27
- :'tag_id' => :'tag_id',
28
- :'name' => :'name',
29
- :'value' => :'value'
30
- }
31
- end
32
-
33
- # Attribute type mapping.
34
- def self.openapi_types
35
- {
36
- :'tag_id' => :'String',
37
- :'name' => :'String',
38
- :'value' => :'String'
39
- }
40
- end
41
-
42
- # List of attributes with nullable: true
43
- def self.openapi_nullable
44
- Set.new([
45
- ])
46
- end
47
-
48
- # Initializes the object
49
- # @param [Hash] attributes Model attributes in the form of hash
50
- def initialize(attributes = {})
51
- if (!attributes.is_a?(Hash))
52
- fail ArgumentError, "The input argument (attributes) must be a hash in `TopologicalInventoryApiClient::Tagging` initialize method"
53
- end
54
-
55
- # check to see if the attribute exists and convert string to symbol for hash key
56
- attributes = attributes.each_with_object({}) { |(k, v), h|
57
- if (!self.class.attribute_map.key?(k.to_sym))
58
- fail ArgumentError, "`#{k}` is not a valid attribute in `TopologicalInventoryApiClient::Tagging`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
59
- end
60
- h[k.to_sym] = v
61
- }
62
-
63
- if attributes.key?(:'tag_id')
64
- self.tag_id = attributes[:'tag_id']
65
- end
66
-
67
- if attributes.key?(:'name')
68
- self.name = attributes[:'name']
69
- end
70
-
71
- if attributes.key?(:'value')
72
- self.value = attributes[:'value']
73
- end
74
- end
75
-
76
- # Show invalid properties with the reasons. Usually used together with valid?
77
- # @return Array for valid properties with the reasons
78
- def list_invalid_properties
79
- invalid_properties = Array.new
80
- pattern = Regexp.new(/^\d+$/)
81
- if !@tag_id.nil? && @tag_id !~ pattern
82
- invalid_properties.push("invalid value for \"tag_id\", must conform to the pattern #{pattern}.")
83
- end
84
-
85
- invalid_properties
86
- end
87
-
88
- # Check to see if the all the properties in the model are valid
89
- # @return true if the model is valid
90
- def valid?
91
- return false if !@tag_id.nil? && @tag_id !~ Regexp.new(/^\d+$/)
92
- true
93
- end
94
-
95
- # Custom attribute writer method with validation
96
- # @param [Object] tag_id Value to be assigned
97
- def tag_id=(tag_id)
98
- pattern = Regexp.new(/^\d+$/)
99
- if !tag_id.nil? && tag_id !~ pattern
100
- fail ArgumentError, "invalid value for \"tag_id\", must conform to the pattern #{pattern}."
101
- end
102
-
103
- @tag_id = tag_id
104
- end
105
-
106
- # Checks equality by comparing each attribute.
107
- # @param [Object] Object to be compared
108
- def ==(o)
109
- return true if self.equal?(o)
110
- self.class == o.class &&
111
- tag_id == o.tag_id &&
112
- name == o.name &&
113
- value == o.value
114
- end
115
-
116
- # @see the `==` method
117
- # @param [Object] Object to be compared
118
- def eql?(o)
119
- self == o
120
- end
121
-
122
- # Calculates hash code according to all attributes.
123
- # @return [Integer] Hash code
124
- def hash
125
- [tag_id, name, value].hash
126
- end
127
-
128
- # Builds the object from hash
129
- # @param [Hash] attributes Model attributes in the form of hash
130
- # @return [Object] Returns the model itself
131
- def self.build_from_hash(attributes)
132
- new.build_from_hash(attributes)
133
- end
134
-
135
- # Builds the object from hash
136
- # @param [Hash] attributes Model attributes in the form of hash
137
- # @return [Object] Returns the model itself
138
- def build_from_hash(attributes)
139
- return nil unless attributes.is_a?(Hash)
140
- self.class.openapi_types.each_pair do |key, type|
141
- if type =~ /\AArray<(.*)>/i
142
- # check to ensure the input is an array given that the attribute
143
- # is documented as an array but the input is not
144
- if attributes[self.class.attribute_map[key]].is_a?(Array)
145
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
146
- end
147
- elsif !attributes[self.class.attribute_map[key]].nil?
148
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
149
- end # or else data not found in attributes(hash), not an issue as the data can be optional
150
- end
151
-
152
- self
153
- end
154
-
155
- # Deserializes the data based on type
156
- # @param string type Data type
157
- # @param string value Value to be deserialized
158
- # @return [Object] Deserialized data
159
- def _deserialize(type, value)
160
- case type.to_sym
161
- when :DateTime
162
- DateTime.parse(value)
163
- when :Date
164
- Date.parse(value)
165
- when :String
166
- value.to_s
167
- when :Integer
168
- value.to_i
169
- when :Float
170
- value.to_f
171
- when :Boolean
172
- if value.to_s =~ /\A(true|t|yes|y|1)\z/i
173
- true
174
- else
175
- false
176
- end
177
- when :Object
178
- # generic object (usually a Hash), return directly
179
- value
180
- when /\AArray<(?<inner_type>.+)>\z/
181
- inner_type = Regexp.last_match[:inner_type]
182
- value.map { |v| _deserialize(inner_type, v) }
183
- when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
184
- k_type = Regexp.last_match[:k_type]
185
- v_type = Regexp.last_match[:v_type]
186
- {}.tap do |hash|
187
- value.each do |k, v|
188
- hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
189
- end
190
- end
191
- else # model
192
- TopologicalInventoryApiClient.const_get(type).build_from_hash(value)
193
- end
194
- end
195
-
196
- # Returns the string representation of the object
197
- # @return [String] String presentation of the object
198
- def to_s
199
- to_hash.to_s
200
- end
201
-
202
- # to_body is an alias to to_hash (backward compatibility)
203
- # @return [Hash] Returns the object in the form of hash
204
- def to_body
205
- to_hash
206
- end
207
-
208
- # Returns the object in the form of hash
209
- # @return [Hash] Returns the object in the form of hash
210
- def to_hash
211
- hash = {}
212
- self.class.attribute_map.each_pair do |attr, param|
213
- value = self.send(attr)
214
- if value.nil?
215
- is_nullable = self.class.openapi_nullable.include?(attr)
216
- next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
217
- end
218
-
219
- hash[param] = _to_hash(value)
220
- end
221
- hash
222
- end
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
- end
242
- end
@@ -1,53 +0,0 @@
1
- =begin
2
- #Topological Inventory
3
-
4
- #Topological Inventory
5
-
6
- The version of the OpenAPI document: 1.0.0
7
- Contact: support@redhat.com
8
- Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 4.2.1
10
-
11
- =end
12
-
13
- require 'spec_helper'
14
- require 'json'
15
- require 'date'
16
-
17
- # Unit tests for TopologicalInventoryApiClient::Tagging
18
- # Automatically generated by openapi-generator (https://openapi-generator.tech)
19
- # Please update as you see appropriate
20
- describe 'Tagging' do
21
- before do
22
- # run before each test
23
- @instance = TopologicalInventoryApiClient::Tagging.new
24
- end
25
-
26
- after do
27
- # run after each test
28
- end
29
-
30
- describe 'test an instance of Tagging' do
31
- it 'should create an instance of Tagging' do
32
- expect(@instance).to be_instance_of(TopologicalInventoryApiClient::Tagging)
33
- end
34
- end
35
- describe 'test attribute "tag_id"' do
36
- it 'should work' do
37
- # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
38
- end
39
- end
40
-
41
- describe 'test attribute "name"' do
42
- it 'should work' do
43
- # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
44
- end
45
- end
46
-
47
- describe 'test attribute "value"' do
48
- it 'should work' do
49
- # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
50
- end
51
- end
52
-
53
- end