autosde_openapi_client 2.1.0 → 2.1.2

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: de6edb72bc00c2d9f56eeef9932ec152825d93664d44cfd5c5c975d8ecfe823c
4
- data.tar.gz: c4f69368986a5973a27d60c38cac75ace4b5d7069da73c32d146142b41533c4b
3
+ metadata.gz: 489bace58d81f5025197702fe1294f93c5c670f8a0ef47ea001792b0fceedbb6
4
+ data.tar.gz: 303783211658c054c4def2257fa24ba873b3db5793fd6663b46cf4ecc460eab4
5
5
  SHA512:
6
- metadata.gz: 7261263d0f78fa01ba9cdf0cc9b07ad50b785801c51891f43d81c9669edb6e344ea6ce48afb492d1619307208f4c55589fe091a33a7b0b5b0156ffe395f11e7e
7
- data.tar.gz: '08fdd17cce09f955aedd9cf016053f33a70405bfa90502758839ec2491110e945426deab73ba58a7a6f92dacafa65397abb425597964e9c95ae2552a16698840'
6
+ metadata.gz: 932da001bb150e283b0ac57654b8022b9691f7a23dbbce5e176225d4b9e5c20f1dcfd5a0b60951a1b93c262b83768ab2ff31701d24562b16e5526fe81db87bb0
7
+ data.tar.gz: 912cc41116263c386bd348100fc3696fadbe45b7d17ede158de4e586da97106159023a6bb725b97474915c7f1e1d75c472742e56a8dfcede2342762b0e91e769
data/README.md CHANGED
@@ -264,6 +264,7 @@ Class | Method | HTTP request | Description
264
264
  - [AutosdeOpenapiClient::StorageSystemUpdate](docs/StorageSystemUpdate.md)
265
265
  - [AutosdeOpenapiClient::SystemType](docs/SystemType.md)
266
266
  - [AutosdeOpenapiClient::SystemTypeCreate](docs/SystemTypeCreate.md)
267
+ - [AutosdeOpenapiClient::SystemTypeResponse](docs/SystemTypeResponse.md)
267
268
  - [AutosdeOpenapiClient::User](docs/User.md)
268
269
  - [AutosdeOpenapiClient::UserCreate](docs/UserCreate.md)
269
270
  - [AutosdeOpenapiClient::UserUpdate](docs/UserUpdate.md)
data/docs/StorageHost.md CHANGED
@@ -4,6 +4,7 @@
4
4
 
5
5
  | Name | Type | Description | Notes |
6
6
  | ---- | ---- | ----------- | ----- |
7
+ | **addresses** | [**Address**](Address.md) | | [optional] |
7
8
  | **component_state** | **String** | component_state | [optional] |
8
9
  | **description** | **String** | description | [optional] |
9
10
  | **host_cluster** | [**HostCluster**](HostCluster.md) | | [optional] |
@@ -21,6 +22,7 @@
21
22
  require 'autosde_openapi_client'
22
23
 
23
24
  instance = AutosdeOpenapiClient::StorageHost.new(
25
+ addresses: null,
24
26
  component_state: null,
25
27
  description: null,
26
28
  host_cluster: null,
@@ -12,7 +12,7 @@ All URIs are relative to *http://localhost:9000/site-manager/api/v1/engine*
12
12
 
13
13
  ## system_types_get
14
14
 
15
- > <Array<SystemType>> system_types_get
15
+ > <Array<SystemTypeResponse>> system_types_get
16
16
 
17
17
 
18
18
 
@@ -42,7 +42,7 @@ end
42
42
 
43
43
  This returns an Array which contains the response data, status code and headers.
44
44
 
45
- > <Array(<Array<SystemType>>, Integer, Hash)> system_types_get_with_http_info
45
+ > <Array(<Array<SystemTypeResponse>>, Integer, Hash)> system_types_get_with_http_info
46
46
 
47
47
  ```ruby
48
48
  begin
@@ -50,7 +50,7 @@ begin
50
50
  data, status_code, headers = api_instance.system_types_get_with_http_info
51
51
  p status_code # => 2xx
52
52
  p headers # => { ... }
53
- p data # => <Array<SystemType>>
53
+ p data # => <Array<SystemTypeResponse>>
54
54
  rescue AutosdeOpenapiClient::ApiError => e
55
55
  puts "Error when calling SystemTypeApi->system_types_get_with_http_info: #{e}"
56
56
  end
@@ -62,7 +62,7 @@ This endpoint does not need any parameter.
62
62
 
63
63
  ### Return type
64
64
 
65
- [**Array&lt;SystemType&gt;**](SystemType.md)
65
+ [**Array&lt;SystemTypeResponse&gt;**](SystemTypeResponse.md)
66
66
 
67
67
  ### Authorization
68
68
 
@@ -5,9 +5,9 @@
5
5
  | Name | Type | Description | Notes |
6
6
  | ---- | ---- | ----------- | ----- |
7
7
  | **component_state** | **String** | component_state | [optional] |
8
- | **name** | **String** | name | [optional][default to &#39;IBM_FlashSystems&#39;] |
8
+ | **name** | **String** | name | [optional] |
9
9
  | **short_version** | **String** | short_version | [optional] |
10
- | **super_type** | **String** | super_type | [optional][default to &#39;null&#39;] |
10
+ | **super_type** | **Integer** | super_type | [optional] |
11
11
  | **uuid** | **String** | uuid | [optional] |
12
12
  | **version** | **String** | SystemType version | [optional] |
13
13
 
@@ -0,0 +1,28 @@
1
+ # AutosdeOpenapiClient::SystemTypeResponse
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **capability_values_json** | **String** | capability_values_json | [optional] |
8
+ | **component_state** | **String** | component_state | [optional] |
9
+ | **name** | **String** | name | [optional][default to &#39;IBM_FlashSystems&#39;] |
10
+ | **short_version** | **String** | short_version | [optional] |
11
+ | **uuid** | **String** | uuid | [optional] |
12
+ | **version** | **String** | SystemType version | [optional] |
13
+
14
+ ## Example
15
+
16
+ ```ruby
17
+ require 'autosde_openapi_client'
18
+
19
+ instance = AutosdeOpenapiClient::SystemTypeResponse.new(
20
+ capability_values_json: null,
21
+ component_state: null,
22
+ name: null,
23
+ short_version: null,
24
+ uuid: null,
25
+ version: null
26
+ )
27
+ ```
28
+
@@ -20,14 +20,14 @@ module AutosdeOpenapiClient
20
20
  @api_client = api_client
21
21
  end
22
22
  # @param [Hash] opts the optional parameters
23
- # @return [Array<SystemType>]
23
+ # @return [Array<SystemTypeResponse>]
24
24
  def system_types_get(opts = {})
25
25
  data, _status_code, _headers = system_types_get_with_http_info(opts)
26
26
  data
27
27
  end
28
28
 
29
29
  # @param [Hash] opts the optional parameters
30
- # @return [Array<(Array<SystemType>, Integer, Hash)>] Array<SystemType> data, response status code and response headers
30
+ # @return [Array<(Array<SystemTypeResponse>, Integer, Hash)>] Array<SystemTypeResponse> data, response status code and response headers
31
31
  def system_types_get_with_http_info(opts = {})
32
32
  if @api_client.config.debugging
33
33
  @api_client.config.logger.debug 'Calling API: SystemTypeApi.system_types_get ...'
@@ -50,7 +50,7 @@ module AutosdeOpenapiClient
50
50
  post_body = opts[:debug_body]
51
51
 
52
52
  # return_type
53
- return_type = opts[:debug_return_type] || 'Array<SystemType>'
53
+ return_type = opts[:debug_return_type] || 'Array<SystemTypeResponse>'
54
54
 
55
55
  # auth_names
56
56
  auth_names = opts[:debug_auth_names] || ['bearerAuth']
@@ -16,6 +16,8 @@ require 'time'
16
16
  module AutosdeOpenapiClient
17
17
  # StorageHost
18
18
  class StorageHost
19
+ attr_accessor :addresses
20
+
19
21
  # component_state
20
22
  attr_accessor :component_state
21
23
 
@@ -68,6 +70,7 @@ module AutosdeOpenapiClient
68
70
  # Attribute mapping from ruby-style variable name to JSON key.
69
71
  def self.attribute_map
70
72
  {
73
+ :'addresses' => :'addresses',
71
74
  :'component_state' => :'component_state',
72
75
  :'description' => :'description',
73
76
  :'host_cluster' => :'host_cluster',
@@ -89,6 +92,7 @@ module AutosdeOpenapiClient
89
92
  # Attribute type mapping.
90
93
  def self.openapi_types
91
94
  {
95
+ :'addresses' => :'Address',
92
96
  :'component_state' => :'String',
93
97
  :'description' => :'String',
94
98
  :'host_cluster' => :'HostCluster',
@@ -123,6 +127,10 @@ module AutosdeOpenapiClient
123
127
  h[k.to_sym] = v
124
128
  }
125
129
 
130
+ if attributes.key?(:'addresses')
131
+ self.addresses = attributes[:'addresses']
132
+ end
133
+
126
134
  if attributes.key?(:'component_state')
127
135
  self.component_state = attributes[:'component_state']
128
136
  end
@@ -199,6 +207,7 @@ module AutosdeOpenapiClient
199
207
  def ==(o)
200
208
  return true if self.equal?(o)
201
209
  self.class == o.class &&
210
+ addresses == o.addresses &&
202
211
  component_state == o.component_state &&
203
212
  description == o.description &&
204
213
  host_cluster == o.host_cluster &&
@@ -220,7 +229,7 @@ module AutosdeOpenapiClient
220
229
  # Calculates hash code according to all attributes.
221
230
  # @return [Integer] Hash code
222
231
  def hash
223
- [component_state, description, host_cluster, host_cluster_name, io_groups, name, status, storage_system, uuid, volumes].hash
232
+ [addresses, component_state, description, host_cluster, host_cluster_name, io_groups, name, status, storage_system, uuid, volumes].hash
224
233
  end
225
234
 
226
235
  # Builds the object from hash
@@ -79,7 +79,7 @@ module AutosdeOpenapiClient
79
79
  :'component_state' => :'String',
80
80
  :'name' => :'String',
81
81
  :'short_version' => :'String',
82
- :'super_type' => :'String',
82
+ :'super_type' => :'Integer',
83
83
  :'uuid' => :'String',
84
84
  :'version' => :'String'
85
85
  }
@@ -112,8 +112,6 @@ module AutosdeOpenapiClient
112
112
 
113
113
  if attributes.key?(:'name')
114
114
  self.name = attributes[:'name']
115
- else
116
- self.name = 'IBM_FlashSystems'
117
115
  end
118
116
 
119
117
  if attributes.key?(:'short_version')
@@ -122,8 +120,6 @@ module AutosdeOpenapiClient
122
120
 
123
121
  if attributes.key?(:'super_type')
124
122
  self.super_type = attributes[:'super_type']
125
- else
126
- self.super_type = 'null'
127
123
  end
128
124
 
129
125
  if attributes.key?(:'uuid')
@@ -143,10 +139,6 @@ module AutosdeOpenapiClient
143
139
  invalid_properties.push('invalid value for "component_state", the character length must be smaller than or equal to 32.')
144
140
  end
145
141
 
146
- if !@name.nil? && @name.to_s.length > 255
147
- invalid_properties.push('invalid value for "name", the character length must be smaller than or equal to 255.')
148
- end
149
-
150
142
  if !@short_version.nil? && @short_version.to_s.length > 255
151
143
  invalid_properties.push('invalid value for "short_version", the character length must be smaller than or equal to 255.')
152
144
  end
@@ -160,9 +152,6 @@ module AutosdeOpenapiClient
160
152
  component_state_validator = EnumAttributeValidator.new('String', ["PENDING_CREATION", "CREATED", "DELETED", "PENDING_DELETION", "MODIFICATION", "PENDING_MODIFICATION"])
161
153
  return false unless component_state_validator.valid?(@component_state)
162
154
  return false if !@component_state.nil? && @component_state.to_s.length > 32
163
- name_validator = EnumAttributeValidator.new('String', ["IBM_FlashSystems", "a_line", "xiv", "ds8000", "vmax", "netapp", "ds8x00"])
164
- return false unless name_validator.valid?(@name)
165
- return false if !@name.nil? && @name.to_s.length > 255
166
155
  return false if !@short_version.nil? && @short_version.to_s.length > 255
167
156
  true
168
157
  end
@@ -177,16 +166,6 @@ module AutosdeOpenapiClient
177
166
  @component_state = component_state
178
167
  end
179
168
 
180
- # Custom attribute writer method checking allowed values (enum).
181
- # @param [Object] name Object to be assigned
182
- def name=(name)
183
- validator = EnumAttributeValidator.new('String', ["IBM_FlashSystems", "a_line", "xiv", "ds8000", "vmax", "netapp", "ds8x00"])
184
- unless validator.valid?(name)
185
- fail ArgumentError, "invalid value for \"name\", must be one of #{validator.allowable_values}."
186
- end
187
- @name = name
188
- end
189
-
190
169
  # Custom attribute writer method with validation
191
170
  # @param [Object] short_version Value to be assigned
192
171
  def short_version=(short_version)
@@ -0,0 +1,343 @@
1
+ =begin
2
+ #Site Manager API
3
+
4
+ #Site Manager API
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+ Contact: autosde@il.ibm.com
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 5.0.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module AutosdeOpenapiClient
17
+ # TODO add description
18
+ class SystemTypeResponse
19
+ # capability_values_json
20
+ attr_accessor :capability_values_json
21
+
22
+ # component_state
23
+ attr_accessor :component_state
24
+
25
+ # name
26
+ attr_accessor :name
27
+
28
+ # short_version
29
+ attr_accessor :short_version
30
+
31
+ # uuid
32
+ attr_accessor :uuid
33
+
34
+ # SystemType version
35
+ attr_accessor :version
36
+
37
+ class EnumAttributeValidator
38
+ attr_reader :datatype
39
+ attr_reader :allowable_values
40
+
41
+ def initialize(datatype, allowable_values)
42
+ @allowable_values = allowable_values.map do |value|
43
+ case datatype.to_s
44
+ when /Integer/i
45
+ value.to_i
46
+ when /Float/i
47
+ value.to_f
48
+ else
49
+ value
50
+ end
51
+ end
52
+ end
53
+
54
+ def valid?(value)
55
+ !value || allowable_values.include?(value)
56
+ end
57
+ end
58
+
59
+ # Attribute mapping from ruby-style variable name to JSON key.
60
+ def self.attribute_map
61
+ {
62
+ :'capability_values_json' => :'capability_values_json',
63
+ :'component_state' => :'component_state',
64
+ :'name' => :'name',
65
+ :'short_version' => :'short_version',
66
+ :'uuid' => :'uuid',
67
+ :'version' => :'version'
68
+ }
69
+ end
70
+
71
+ # Returns all the JSON keys this model knows about
72
+ def self.acceptable_attributes
73
+ attribute_map.values
74
+ end
75
+
76
+ # Attribute type mapping.
77
+ def self.openapi_types
78
+ {
79
+ :'capability_values_json' => :'String',
80
+ :'component_state' => :'String',
81
+ :'name' => :'String',
82
+ :'short_version' => :'String',
83
+ :'uuid' => :'String',
84
+ :'version' => :'String'
85
+ }
86
+ end
87
+
88
+ # List of attributes with nullable: true
89
+ def self.openapi_nullable
90
+ Set.new([
91
+ ])
92
+ end
93
+
94
+ # Initializes the object
95
+ # @param [Hash] attributes Model attributes in the form of hash
96
+ def initialize(attributes = {})
97
+ if (!attributes.is_a?(Hash))
98
+ fail ArgumentError, "The input argument (attributes) must be a hash in `AutosdeOpenapiClient::SystemTypeResponse` initialize method"
99
+ end
100
+
101
+ # check to see if the attribute exists and convert string to symbol for hash key
102
+ attributes = attributes.each_with_object({}) { |(k, v), h|
103
+ if (!self.class.attribute_map.key?(k.to_sym))
104
+ fail ArgumentError, "`#{k}` is not a valid attribute in `AutosdeOpenapiClient::SystemTypeResponse`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
105
+ end
106
+ h[k.to_sym] = v
107
+ }
108
+
109
+ if attributes.key?(:'capability_values_json')
110
+ self.capability_values_json = attributes[:'capability_values_json']
111
+ end
112
+
113
+ if attributes.key?(:'component_state')
114
+ self.component_state = attributes[:'component_state']
115
+ end
116
+
117
+ if attributes.key?(:'name')
118
+ self.name = attributes[:'name']
119
+ else
120
+ self.name = 'IBM_FlashSystems'
121
+ end
122
+
123
+ if attributes.key?(:'short_version')
124
+ self.short_version = attributes[:'short_version']
125
+ end
126
+
127
+ if attributes.key?(:'uuid')
128
+ self.uuid = attributes[:'uuid']
129
+ end
130
+
131
+ if attributes.key?(:'version')
132
+ self.version = attributes[:'version']
133
+ end
134
+ end
135
+
136
+ # Show invalid properties with the reasons. Usually used together with valid?
137
+ # @return Array for valid properties with the reasons
138
+ def list_invalid_properties
139
+ invalid_properties = Array.new
140
+ if !@component_state.nil? && @component_state.to_s.length > 32
141
+ invalid_properties.push('invalid value for "component_state", the character length must be smaller than or equal to 32.')
142
+ end
143
+
144
+ if !@name.nil? && @name.to_s.length > 255
145
+ invalid_properties.push('invalid value for "name", the character length must be smaller than or equal to 255.')
146
+ end
147
+
148
+ if !@short_version.nil? && @short_version.to_s.length > 255
149
+ invalid_properties.push('invalid value for "short_version", the character length must be smaller than or equal to 255.')
150
+ end
151
+
152
+ invalid_properties
153
+ end
154
+
155
+ # Check to see if the all the properties in the model are valid
156
+ # @return true if the model is valid
157
+ def valid?
158
+ component_state_validator = EnumAttributeValidator.new('String', ["PENDING_CREATION", "CREATED", "DELETED", "PENDING_DELETION", "MODIFICATION", "PENDING_MODIFICATION"])
159
+ return false unless component_state_validator.valid?(@component_state)
160
+ return false if !@component_state.nil? && @component_state.to_s.length > 32
161
+ name_validator = EnumAttributeValidator.new('String', ["IBM_FlashSystems", "a_line", "xiv", "ds8000", "vmax", "netapp", "ds8x00"])
162
+ return false unless name_validator.valid?(@name)
163
+ return false if !@name.nil? && @name.to_s.length > 255
164
+ return false if !@short_version.nil? && @short_version.to_s.length > 255
165
+ true
166
+ end
167
+
168
+ # Custom attribute writer method checking allowed values (enum).
169
+ # @param [Object] component_state Object to be assigned
170
+ def component_state=(component_state)
171
+ validator = EnumAttributeValidator.new('String', ["PENDING_CREATION", "CREATED", "DELETED", "PENDING_DELETION", "MODIFICATION", "PENDING_MODIFICATION"])
172
+ unless validator.valid?(component_state)
173
+ fail ArgumentError, "invalid value for \"component_state\", must be one of #{validator.allowable_values}."
174
+ end
175
+ @component_state = component_state
176
+ end
177
+
178
+ # Custom attribute writer method checking allowed values (enum).
179
+ # @param [Object] name Object to be assigned
180
+ def name=(name)
181
+ validator = EnumAttributeValidator.new('String', ["IBM_FlashSystems", "a_line", "xiv", "ds8000", "vmax", "netapp", "ds8x00"])
182
+ unless validator.valid?(name)
183
+ fail ArgumentError, "invalid value for \"name\", must be one of #{validator.allowable_values}."
184
+ end
185
+ @name = name
186
+ end
187
+
188
+ # Custom attribute writer method with validation
189
+ # @param [Object] short_version Value to be assigned
190
+ def short_version=(short_version)
191
+ if !short_version.nil? && short_version.to_s.length > 255
192
+ fail ArgumentError, 'invalid value for "short_version", the character length must be smaller than or equal to 255.'
193
+ end
194
+
195
+ @short_version = short_version
196
+ end
197
+
198
+ # Checks equality by comparing each attribute.
199
+ # @param [Object] Object to be compared
200
+ def ==(o)
201
+ return true if self.equal?(o)
202
+ self.class == o.class &&
203
+ capability_values_json == o.capability_values_json &&
204
+ component_state == o.component_state &&
205
+ name == o.name &&
206
+ short_version == o.short_version &&
207
+ uuid == o.uuid &&
208
+ version == o.version
209
+ end
210
+
211
+ # @see the `==` method
212
+ # @param [Object] Object to be compared
213
+ def eql?(o)
214
+ self == o
215
+ end
216
+
217
+ # Calculates hash code according to all attributes.
218
+ # @return [Integer] Hash code
219
+ def hash
220
+ [capability_values_json, component_state, name, short_version, uuid, version].hash
221
+ end
222
+
223
+ # Builds the object from hash
224
+ # @param [Hash] attributes Model attributes in the form of hash
225
+ # @return [Object] Returns the model itself
226
+ def self.build_from_hash(attributes)
227
+ new.build_from_hash(attributes)
228
+ end
229
+
230
+ # Builds the object from hash
231
+ # @param [Hash] attributes Model attributes in the form of hash
232
+ # @return [Object] Returns the model itself
233
+ def build_from_hash(attributes)
234
+ return nil unless attributes.is_a?(Hash)
235
+ self.class.openapi_types.each_pair do |key, type|
236
+ if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
237
+ self.send("#{key}=", nil)
238
+ elsif type =~ /\AArray<(.*)>/i
239
+ # check to ensure the input is an array given that the attribute
240
+ # is documented as an array but the input is not
241
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
242
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
243
+ end
244
+ elsif !attributes[self.class.attribute_map[key]].nil?
245
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
246
+ end
247
+ end
248
+
249
+ self
250
+ end
251
+
252
+ # Deserializes the data based on type
253
+ # @param string type Data type
254
+ # @param string value Value to be deserialized
255
+ # @return [Object] Deserialized data
256
+ def _deserialize(type, value)
257
+ case type.to_sym
258
+ when :Time
259
+ Time.parse(value)
260
+ when :Date
261
+ Date.parse(value)
262
+ when :String
263
+ value.to_s
264
+ when :Integer
265
+ value.to_i
266
+ when :Float
267
+ value.to_f
268
+ when :Boolean
269
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
270
+ true
271
+ else
272
+ false
273
+ end
274
+ when :Object
275
+ # generic object (usually a Hash), return directly
276
+ value
277
+ when /\AArray<(?<inner_type>.+)>\z/
278
+ inner_type = Regexp.last_match[:inner_type]
279
+ value.map { |v| _deserialize(inner_type, v) }
280
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
281
+ k_type = Regexp.last_match[:k_type]
282
+ v_type = Regexp.last_match[:v_type]
283
+ {}.tap do |hash|
284
+ value.each do |k, v|
285
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
286
+ end
287
+ end
288
+ else # model
289
+ # models (e.g. Pet) or oneOf
290
+ klass = AutosdeOpenapiClient.const_get(type)
291
+ klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
292
+ end
293
+ end
294
+
295
+ # Returns the string representation of the object
296
+ # @return [String] String presentation of the object
297
+ def to_s
298
+ to_hash.to_s
299
+ end
300
+
301
+ # to_body is an alias to to_hash (backward compatibility)
302
+ # @return [Hash] Returns the object in the form of hash
303
+ def to_body
304
+ to_hash
305
+ end
306
+
307
+ # Returns the object in the form of hash
308
+ # @return [Hash] Returns the object in the form of hash
309
+ def to_hash
310
+ hash = {}
311
+ self.class.attribute_map.each_pair do |attr, param|
312
+ value = self.send(attr)
313
+ if value.nil?
314
+ is_nullable = self.class.openapi_nullable.include?(attr)
315
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
316
+ end
317
+
318
+ hash[param] = _to_hash(value)
319
+ end
320
+ hash
321
+ end
322
+
323
+ # Outputs non-array value in the form of hash
324
+ # For object, use to_hash. Otherwise, just return the value
325
+ # @param [Object] value Any valid value
326
+ # @return [Hash] Returns the value in the form of hash
327
+ def _to_hash(value)
328
+ if value.is_a?(Array)
329
+ value.compact.map { |v| _to_hash(v) }
330
+ elsif value.is_a?(Hash)
331
+ {}.tap do |hash|
332
+ value.each { |k, v| hash[k] = _to_hash(v) }
333
+ end
334
+ elsif value.respond_to? :to_hash
335
+ value.to_hash
336
+ else
337
+ value
338
+ end
339
+ end
340
+
341
+ end
342
+
343
+ end
@@ -3,7 +3,7 @@
3
3
 
4
4
  #Site Manager API
5
5
 
6
- The version of the OpenAPI document: 2.1.0
6
+ The version of the OpenAPI document: 2.1.2
7
7
  Contact: autosde@il.ibm.com
8
8
  Generated by: https://openapi-generator.tech
9
9
  OpenAPI Generator version: 5.0.0
@@ -11,5 +11,5 @@ OpenAPI Generator version: 5.0.0
11
11
  =end
12
12
 
13
13
  module AutosdeOpenapiClient
14
- VERSION = '2.1.0'
14
+ VERSION = '2.1.2'
15
15
  end
@@ -77,6 +77,7 @@ require 'autosde_openapi_client/models/storage_system_response'
77
77
  require 'autosde_openapi_client/models/storage_system_update'
78
78
  require 'autosde_openapi_client/models/system_type'
79
79
  require 'autosde_openapi_client/models/system_type_create'
80
+ require 'autosde_openapi_client/models/system_type_response'
80
81
  require 'autosde_openapi_client/models/user'
81
82
  require 'autosde_openapi_client/models/user_create'
82
83
  require 'autosde_openapi_client/models/user_update'
@@ -34,7 +34,7 @@ describe 'SystemTypeApi' do
34
34
 
35
35
  # unit tests for system_types_get
36
36
  # @param [Hash] opts the optional parameters
37
- # @return [Array<SystemType>]
37
+ # @return [Array<SystemTypeResponse>]
38
38
  describe 'system_types_get test' do
39
39
  it 'should work' do
40
40
  # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
@@ -25,6 +25,12 @@ describe AutosdeOpenapiClient::StorageHost do
25
25
  expect(instance).to be_instance_of(AutosdeOpenapiClient::StorageHost)
26
26
  end
27
27
  end
28
+ describe 'test attribute "addresses"' do
29
+ it 'should work' do
30
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
31
+ end
32
+ end
33
+
28
34
  describe 'test attribute "component_state"' do
29
35
  it 'should work' do
30
36
  # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
@@ -38,10 +38,6 @@ describe AutosdeOpenapiClient::SystemTypeCreate do
38
38
  describe 'test attribute "name"' do
39
39
  it 'should work' do
40
40
  # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
41
- # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["IBM_FlashSystems", "a_line", "xiv", "ds8000", "vmax", "netapp", "ds8x00"])
42
- # validator.allowable_values.each do |value|
43
- # expect { instance.name = value }.not_to raise_error
44
- # end
45
41
  end
46
42
  end
47
43
 
@@ -0,0 +1,72 @@
1
+ =begin
2
+ #Site Manager API
3
+
4
+ #Site Manager API
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+ Contact: autosde@il.ibm.com
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 5.0.0
10
+
11
+ =end
12
+
13
+ require 'spec_helper'
14
+ require 'json'
15
+ require 'date'
16
+
17
+ # Unit tests for AutosdeOpenapiClient::SystemTypeResponse
18
+ # Automatically generated by openapi-generator (https://openapi-generator.tech)
19
+ # Please update as you see appropriate
20
+ describe AutosdeOpenapiClient::SystemTypeResponse do
21
+ let(:instance) { AutosdeOpenapiClient::SystemTypeResponse.new }
22
+
23
+ describe 'test an instance of SystemTypeResponse' do
24
+ it 'should create an instance of SystemTypeResponse' do
25
+ expect(instance).to be_instance_of(AutosdeOpenapiClient::SystemTypeResponse)
26
+ end
27
+ end
28
+ describe 'test attribute "capability_values_json"' do
29
+ it 'should work' do
30
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
31
+ end
32
+ end
33
+
34
+ describe 'test attribute "component_state"' do
35
+ it 'should work' do
36
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
37
+ # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["PENDING_CREATION", "CREATED", "DELETED", "PENDING_DELETION", "MODIFICATION", "PENDING_MODIFICATION"])
38
+ # validator.allowable_values.each do |value|
39
+ # expect { instance.component_state = value }.not_to raise_error
40
+ # end
41
+ end
42
+ end
43
+
44
+ describe 'test attribute "name"' do
45
+ it 'should work' do
46
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
47
+ # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["IBM_FlashSystems", "a_line", "xiv", "ds8000", "vmax", "netapp", "ds8x00"])
48
+ # validator.allowable_values.each do |value|
49
+ # expect { instance.name = value }.not_to raise_error
50
+ # end
51
+ end
52
+ end
53
+
54
+ describe 'test attribute "short_version"' do
55
+ it 'should work' do
56
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
57
+ end
58
+ end
59
+
60
+ describe 'test attribute "uuid"' do
61
+ it 'should work' do
62
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
63
+ end
64
+ end
65
+
66
+ describe 'test attribute "version"' do
67
+ it 'should work' do
68
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
69
+ end
70
+ end
71
+
72
+ end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: autosde_openapi_client
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.0
4
+ version: 2.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - OpenAPI-Generator
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-01-18 00:00:00.000000000 Z
11
+ date: 2023-01-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: typhoeus
@@ -151,6 +151,7 @@ files:
151
151
  - docs/SystemType.md
152
152
  - docs/SystemTypeApi.md
153
153
  - docs/SystemTypeCreate.md
154
+ - docs/SystemTypeResponse.md
154
155
  - docs/User.md
155
156
  - docs/UserApi.md
156
157
  - docs/UserCreate.md
@@ -259,6 +260,7 @@ files:
259
260
  - lib/autosde_openapi_client/models/storage_system_update.rb
260
261
  - lib/autosde_openapi_client/models/system_type.rb
261
262
  - lib/autosde_openapi_client/models/system_type_create.rb
263
+ - lib/autosde_openapi_client/models/system_type_response.rb
262
264
  - lib/autosde_openapi_client/models/user.rb
263
265
  - lib/autosde_openapi_client/models/user_create.rb
264
266
  - lib/autosde_openapi_client/models/user_update.rb
@@ -361,6 +363,7 @@ files:
361
363
  - spec/models/storage_system_spec.rb
362
364
  - spec/models/storage_system_update_spec.rb
363
365
  - spec/models/system_type_create_spec.rb
366
+ - spec/models/system_type_response_spec.rb
364
367
  - spec/models/system_type_spec.rb
365
368
  - spec/models/user_create_spec.rb
366
369
  - spec/models/user_spec.rb
@@ -395,106 +398,107 @@ signing_key:
395
398
  specification_version: 4
396
399
  summary: Site Manager API Ruby Gem
397
400
  test_files:
398
- - spec/api/storage_resource_api_spec.rb
399
- - spec/api/host_cluster_membership_api_spec.rb
400
- - spec/api/native_capability_api_spec.rb
401
- - spec/api/host_volume_connection_api_spec.rb
402
- - spec/api/refresh_system_api_spec.rb
403
- - spec/api/service_abstract_capability_value_api_spec.rb
404
- - spec/api/job_api_spec.rb
405
- - spec/api/host_cluster_api_spec.rb
406
- - spec/api/profile_api_spec.rb
407
- - spec/api/snapshot_api_spec.rb
408
- - spec/api/storage_host_api_spec.rb
409
- - spec/api/event_api_spec.rb
410
401
  - spec/api/auto_sde_project_api_spec.rb
411
- - spec/api/account_api_spec.rb
412
- - spec/api/address_api_spec.rb
413
- - spec/api/validate_system_api_spec.rb
414
- - spec/api/authentication_api_spec.rb
415
- - spec/api/host_api_spec.rb
416
402
  - spec/api/volume_api_spec.rb
403
+ - spec/api/host_volume_connection_api_spec.rb
404
+ - spec/api/host_cluster_membership_api_spec.rb
405
+ - spec/api/capability_translation_api_spec.rb
406
+ - spec/api/service_abstract_capability_value_api_spec.rb
407
+ - spec/api/abstract_capability_api_spec.rb
417
408
  - spec/api/storage_system_api_spec.rb
409
+ - spec/api/refresh_system_api_spec.rb
418
410
  - spec/api/user_api_spec.rb
411
+ - spec/api/host_api_spec.rb
412
+ - spec/api/authentication_api_spec.rb
413
+ - spec/api/storage_resource_api_spec.rb
414
+ - spec/api/host_cluster_api_spec.rb
415
+ - spec/api/native_capability_api_spec.rb
416
+ - spec/api/provisioning_strategy_api_spec.rb
417
+ - spec/api/address_api_spec.rb
418
+ - spec/api/account_api_spec.rb
419
+ - spec/api/auto_sde_role_api_spec.rb
419
420
  - spec/api/system_type_api_spec.rb
420
- - spec/api/capability_translation_api_spec.rb
421
- - spec/api/storage_host_wwpn_candidates_api_spec.rb
422
421
  - spec/api/host_cluster_volume_mapping_api_spec.rb
423
- - spec/api/auto_sde_role_api_spec.rb
424
- - spec/api/abstract_capability_api_spec.rb
425
- - spec/api/celery_config_api_spec.rb
426
- - spec/api/provisioning_strategy_api_spec.rb
422
+ - spec/api/event_api_spec.rb
427
423
  - spec/api/storage_hosts_mapping_api_spec.rb
424
+ - spec/api/celery_config_api_spec.rb
425
+ - spec/api/job_api_spec.rb
426
+ - spec/api/profile_api_spec.rb
427
+ - spec/api/storage_host_api_spec.rb
428
428
  - spec/api/service_api_spec.rb
429
+ - spec/api/storage_host_wwpn_candidates_api_spec.rb
429
430
  - spec/api/service_resource_attachment_api_spec.rb
431
+ - spec/api/validate_system_api_spec.rb
432
+ - spec/api/snapshot_api_spec.rb
430
433
  - spec/api_client_spec.rb
431
434
  - spec/configuration_spec.rb
432
- - spec/models/service_spec.rb
433
- - spec/models/storage_hosts_mapping_response_spec.rb
434
- - spec/models/account_spec.rb
435
- - spec/models/service_create_spec.rb
436
- - spec/models/host_volume_connection_spec.rb
437
- - spec/models/snapshot_create_spec.rb
438
- - spec/models/auto_sde_role_spec.rb
439
- - spec/models/storage_host_create_spec.rb
435
+ - spec/models/storage_host_spec.rb
440
436
  - spec/models/host_cluster_volume_mapping_create_spec.rb
441
- - spec/models/system_type_create_spec.rb
442
437
  - spec/models/storage_hosts_mapping_create_spec.rb
443
- - spec/models/auth_response_spec.rb
444
- - spec/models/capability_translation_spec.rb
445
- - spec/models/service_abstract_capability_value_spec.rb
446
- - spec/models/volume_response_spec.rb
447
- - spec/models/event_response_spec.rb
448
- - spec/models/profile_spec.rb
449
- - spec/models/async_response_spec.rb
450
- - spec/models/native_capability_spec.rb
451
- - spec/models/volume_create_spec.rb
452
- - spec/models/snapshot_spec.rb
453
- - spec/models/account_post_response_spec.rb
454
- - spec/models/host_cluster_spec.rb
438
+ - spec/models/service_create_spec.rb
455
439
  - spec/models/refresh_system_spec.rb
456
- - spec/models/storage_hosts_mapping_spec.rb
457
- - spec/models/storage_system_spec.rb
458
- - spec/models/celery_config_spec.rb
459
- - spec/models/service_response_spec.rb
460
- - spec/models/event_spec.rb
461
- - spec/models/abstract_capability_response_spec.rb
462
- - spec/models/authentication_spec.rb
463
- - spec/models/account_post_request_spec.rb
440
+ - spec/models/async_response_spec.rb
441
+ - spec/models/user_spec.rb
442
+ - spec/models/auth_response_spec.rb
443
+ - spec/models/storage_system_update_spec.rb
444
+ - spec/models/system_type_create_spec.rb
464
445
  - spec/models/storage_system_response_spec.rb
446
+ - spec/models/volume_spec.rb
447
+ - spec/models/account_post_request_spec.rb
448
+ - spec/models/storage_system_create_spec.rb
449
+ - spec/models/storage_system_spec.rb
450
+ - spec/models/snapshot_spec.rb
465
451
  - spec/models/address_create_spec.rb
466
- - spec/models/storage_host_update_spec.rb
467
- - spec/models/user_spec.rb
468
- - spec/models/auto_sde_project_spec.rb
469
- - spec/models/storage_resource_spec.rb
470
452
  - spec/models/storage_resource_update_spec.rb
471
- - spec/models/host_cluster_membership_spec.rb
472
- - spec/models/volume_spec.rb
453
+ - spec/models/host_cluster_create_spec.rb
454
+ - spec/models/host_volume_connection_spec.rb
455
+ - spec/models/job_create_spec.rb
456
+ - spec/models/snapshot_create_spec.rb
457
+ - spec/models/storage_resource_response_spec.rb
458
+ - spec/models/host_create_spec.rb
473
459
  - spec/models/storage_host_wwpn_candidates_spec.rb
474
- - spec/models/abstract_capability_spec.rb
475
- - spec/models/user_create_spec.rb
460
+ - spec/models/service_abstract_capability_value_response_spec.rb
476
461
  - spec/models/validate_system_spec.rb
477
- - spec/models/storage_system_update_spec.rb
478
- - spec/models/storage_resource_create_spec.rb
479
- - spec/models/job_spec.rb
480
- - spec/models/host_cluster_volume_mapping_response_spec.rb
481
- - spec/models/storage_system_create_spec.rb
482
462
  - spec/models/host_cluster_volume_mapping_spec.rb
483
- - spec/models/host_volume_connection_create_spec.rb
484
- - spec/models/job_create_spec.rb
485
- - spec/models/service_abstract_capability_value_response_spec.rb
486
- - spec/models/service_resource_attachment_spec.rb
487
- - spec/models/host_cluster_create_spec.rb
488
- - spec/models/storage_host_response_spec.rb
489
- - spec/models/storage_host_spec.rb
490
- - spec/models/volume_update_spec.rb
463
+ - spec/models/celery_config_spec.rb
464
+ - spec/models/profile_spec.rb
491
465
  - spec/models/user_update_spec.rb
492
- - spec/models/provisioning_strategy_spec.rb
493
- - spec/models/host_cluster_response_spec.rb
494
- - spec/models/system_type_spec.rb
495
- - spec/models/host_create_spec.rb
466
+ - spec/models/native_capability_spec.rb
496
467
  - spec/models/host_spec.rb
497
- - spec/models/storage_resource_response_spec.rb
498
- - spec/models/capability_translation_create_spec.rb
468
+ - spec/models/host_volume_connection_create_spec.rb
469
+ - spec/models/job_spec.rb
470
+ - spec/models/system_type_spec.rb
471
+ - spec/models/provisioning_strategy_spec.rb
499
472
  - spec/models/address_spec.rb
473
+ - spec/models/capability_translation_spec.rb
474
+ - spec/models/storage_resource_spec.rb
475
+ - spec/models/user_create_spec.rb
476
+ - spec/models/volume_response_spec.rb
477
+ - spec/models/storage_host_update_spec.rb
478
+ - spec/models/abstract_capability_response_spec.rb
479
+ - spec/models/storage_resource_create_spec.rb
480
+ - spec/models/volume_update_spec.rb
481
+ - spec/models/storage_hosts_mapping_response_spec.rb
482
+ - spec/models/service_response_spec.rb
483
+ - spec/models/storage_hosts_mapping_spec.rb
484
+ - spec/models/storage_host_response_spec.rb
485
+ - spec/models/auto_sde_project_spec.rb
486
+ - spec/models/authentication_spec.rb
487
+ - spec/models/host_cluster_spec.rb
488
+ - spec/models/volume_create_spec.rb
489
+ - spec/models/storage_host_create_spec.rb
490
+ - spec/models/capability_translation_create_spec.rb
491
+ - spec/models/service_abstract_capability_value_spec.rb
492
+ - spec/models/auto_sde_role_spec.rb
493
+ - spec/models/event_spec.rb
494
+ - spec/models/system_type_response_spec.rb
495
+ - spec/models/service_spec.rb
496
+ - spec/models/service_resource_attachment_spec.rb
497
+ - spec/models/host_cluster_response_spec.rb
498
+ - spec/models/abstract_capability_spec.rb
499
+ - spec/models/host_cluster_volume_mapping_response_spec.rb
500
+ - spec/models/account_spec.rb
501
+ - spec/models/account_post_response_spec.rb
502
+ - spec/models/host_cluster_membership_spec.rb
503
+ - spec/models/event_response_spec.rb
500
504
  - spec/spec_helper.rb