autosde_openapi_client 1.1.32 → 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.
Files changed (53) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +15 -7
  3. data/docs/CeleryConfig.md +20 -0
  4. data/docs/CeleryConfigApi.md +140 -0
  5. data/docs/Event.md +4 -0
  6. data/docs/EventApi.md +16 -16
  7. data/docs/EventResponse.md +36 -0
  8. data/docs/Job.md +2 -0
  9. data/docs/JobApi.md +136 -0
  10. data/docs/JobCreate.md +2 -2
  11. data/docs/RefreshSystem.md +18 -0
  12. data/docs/RefreshSystemApi.md +75 -0
  13. data/docs/{StorageHostVolumeMapping.md → StorageHostsMapping.md} +2 -2
  14. data/docs/{StorageHostVolumeMappingApi.md → StorageHostsMappingApi.md} +37 -37
  15. data/docs/{StorageHostVolumeMappingCreate.md → StorageHostsMappingCreate.md} +2 -2
  16. data/docs/{StorageHostVolumeMappingResponse.md → StorageHostsMappingResponse.md} +2 -2
  17. data/docs/StorageSystem.md +2 -2
  18. data/docs/StorageSystemCreate.md +4 -4
  19. data/lib/autosde_openapi_client/api/celery_config_api.rb +136 -0
  20. data/lib/autosde_openapi_client/api/event_api.rb +12 -12
  21. data/lib/autosde_openapi_client/api/job_api.rb +118 -0
  22. data/lib/autosde_openapi_client/api/refresh_system_api.rb +83 -0
  23. data/lib/autosde_openapi_client/api/{storage_host_volume_mapping_api.rb → storage_hosts_mapping_api.rb} +36 -36
  24. data/lib/autosde_openapi_client/models/celery_config.rb +230 -0
  25. data/lib/autosde_openapi_client/models/event.rb +22 -2
  26. data/lib/autosde_openapi_client/models/event_response.rb +310 -0
  27. data/lib/autosde_openapi_client/models/job.rb +11 -1
  28. data/lib/autosde_openapi_client/models/job_create.rb +8 -8
  29. data/lib/autosde_openapi_client/models/refresh_system.rb +220 -0
  30. data/lib/autosde_openapi_client/models/{storage_host_volume_mapping.rb → storage_hosts_mapping.rb} +4 -4
  31. data/lib/autosde_openapi_client/models/{storage_host_volume_mapping_create.rb → storage_hosts_mapping_create.rb} +3 -3
  32. data/lib/autosde_openapi_client/models/{storage_host_volume_mapping_response.rb → storage_hosts_mapping_response.rb} +3 -3
  33. data/lib/autosde_openapi_client/models/storage_system.rb +9 -9
  34. data/lib/autosde_openapi_client/models/storage_system_create.rb +21 -21
  35. data/lib/autosde_openapi_client/version.rb +2 -2
  36. data/lib/autosde_openapi_client.rb +9 -4
  37. data/spec/api/celery_config_api_spec.rb +54 -0
  38. data/spec/api/event_api_spec.rb +4 -4
  39. data/spec/api/job_api_spec.rb +20 -0
  40. data/spec/api/refresh_system_api_spec.rb +45 -0
  41. data/spec/api/{storage_host_volume_mapping_api_spec.rb → storage_hosts_mapping_api_spec.rb} +11 -11
  42. data/spec/models/celery_config_spec.rb +40 -0
  43. data/spec/models/event_response_spec.rb +88 -0
  44. data/spec/models/event_spec.rb +12 -0
  45. data/spec/models/job_create_spec.rb +1 -1
  46. data/spec/models/job_spec.rb +6 -0
  47. data/spec/models/refresh_system_spec.rb +34 -0
  48. data/spec/models/{storage_host_volume_mapping_create_spec.rb → storage_hosts_mapping_create_spec.rb} +6 -6
  49. data/spec/models/{storage_host_volume_mapping_response_spec.rb → storage_hosts_mapping_response_spec.rb} +6 -6
  50. data/spec/models/{storage_host_volume_mapping_spec.rb → storage_hosts_mapping_spec.rb} +6 -6
  51. data/spec/models/storage_system_create_spec.rb +7 -7
  52. data/spec/models/storage_system_spec.rb +1 -1
  53. metadata +38 -18
@@ -72,6 +72,124 @@ module AutosdeOpenapiClient
72
72
  return data, status_code, headers
73
73
  end
74
74
 
75
+ # @param pk [Integer]
76
+ # @param [Hash] opts the optional parameters
77
+ # @return [Array<Job>]
78
+ def jobs_pk_delete(pk, opts = {})
79
+ data, _status_code, _headers = jobs_pk_delete_with_http_info(pk, opts)
80
+ data
81
+ end
82
+
83
+ # @param pk [Integer]
84
+ # @param [Hash] opts the optional parameters
85
+ # @return [Array<(Array<Job>, Integer, Hash)>] Array<Job> data, response status code and response headers
86
+ def jobs_pk_delete_with_http_info(pk, opts = {})
87
+ if @api_client.config.debugging
88
+ @api_client.config.logger.debug 'Calling API: JobApi.jobs_pk_delete ...'
89
+ end
90
+ # verify the required parameter 'pk' is set
91
+ if @api_client.config.client_side_validation && pk.nil?
92
+ fail ArgumentError, "Missing the required parameter 'pk' when calling JobApi.jobs_pk_delete"
93
+ end
94
+ # resource path
95
+ local_var_path = '/jobs/{pk}'.sub('{' + 'pk' + '}', CGI.escape(pk.to_s))
96
+
97
+ # query parameters
98
+ query_params = opts[:query_params] || {}
99
+
100
+ # header parameters
101
+ header_params = opts[:header_params] || {}
102
+ # HTTP header 'Accept' (if needed)
103
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
104
+
105
+ # form parameters
106
+ form_params = opts[:form_params] || {}
107
+
108
+ # http body (model)
109
+ post_body = opts[:debug_body]
110
+
111
+ # return_type
112
+ return_type = opts[:debug_return_type] || 'Array<Job>'
113
+
114
+ # auth_names
115
+ auth_names = opts[:debug_auth_names] || ['bearerAuth']
116
+
117
+ new_options = opts.merge(
118
+ :operation => :"JobApi.jobs_pk_delete",
119
+ :header_params => header_params,
120
+ :query_params => query_params,
121
+ :form_params => form_params,
122
+ :body => post_body,
123
+ :auth_names => auth_names,
124
+ :return_type => return_type
125
+ )
126
+
127
+ data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
128
+ if @api_client.config.debugging
129
+ @api_client.config.logger.debug "API called: JobApi#jobs_pk_delete\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
130
+ end
131
+ return data, status_code, headers
132
+ end
133
+
134
+ # @param pk [Integer]
135
+ # @param [Hash] opts the optional parameters
136
+ # @return [Array<Job>]
137
+ def jobs_pk_get(pk, opts = {})
138
+ data, _status_code, _headers = jobs_pk_get_with_http_info(pk, opts)
139
+ data
140
+ end
141
+
142
+ # @param pk [Integer]
143
+ # @param [Hash] opts the optional parameters
144
+ # @return [Array<(Array<Job>, Integer, Hash)>] Array<Job> data, response status code and response headers
145
+ def jobs_pk_get_with_http_info(pk, opts = {})
146
+ if @api_client.config.debugging
147
+ @api_client.config.logger.debug 'Calling API: JobApi.jobs_pk_get ...'
148
+ end
149
+ # verify the required parameter 'pk' is set
150
+ if @api_client.config.client_side_validation && pk.nil?
151
+ fail ArgumentError, "Missing the required parameter 'pk' when calling JobApi.jobs_pk_get"
152
+ end
153
+ # resource path
154
+ local_var_path = '/jobs/{pk}'.sub('{' + 'pk' + '}', CGI.escape(pk.to_s))
155
+
156
+ # query parameters
157
+ query_params = opts[:query_params] || {}
158
+
159
+ # header parameters
160
+ header_params = opts[:header_params] || {}
161
+ # HTTP header 'Accept' (if needed)
162
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
163
+
164
+ # form parameters
165
+ form_params = opts[:form_params] || {}
166
+
167
+ # http body (model)
168
+ post_body = opts[:debug_body]
169
+
170
+ # return_type
171
+ return_type = opts[:debug_return_type] || 'Array<Job>'
172
+
173
+ # auth_names
174
+ auth_names = opts[:debug_auth_names] || ['bearerAuth']
175
+
176
+ new_options = opts.merge(
177
+ :operation => :"JobApi.jobs_pk_get",
178
+ :header_params => header_params,
179
+ :query_params => query_params,
180
+ :form_params => form_params,
181
+ :body => post_body,
182
+ :auth_names => auth_names,
183
+ :return_type => return_type
184
+ )
185
+
186
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
187
+ if @api_client.config.debugging
188
+ @api_client.config.logger.debug "API called: JobApi#jobs_pk_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
189
+ end
190
+ return data, status_code, headers
191
+ end
192
+
75
193
  # @param job_create [JobCreate]
76
194
  # @param [Hash] opts the optional parameters
77
195
  # @return [Job]
@@ -0,0 +1,83 @@
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 'cgi'
14
+
15
+ module AutosdeOpenapiClient
16
+ class RefreshSystemApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+ # @param refresh_system [RefreshSystem]
23
+ # @param [Hash] opts the optional parameters
24
+ # @return [RefreshSystem]
25
+ def refresh_system_post(refresh_system, opts = {})
26
+ data, _status_code, _headers = refresh_system_post_with_http_info(refresh_system, opts)
27
+ data
28
+ end
29
+
30
+ # @param refresh_system [RefreshSystem]
31
+ # @param [Hash] opts the optional parameters
32
+ # @return [Array<(RefreshSystem, Integer, Hash)>] RefreshSystem data, response status code and response headers
33
+ def refresh_system_post_with_http_info(refresh_system, opts = {})
34
+ if @api_client.config.debugging
35
+ @api_client.config.logger.debug 'Calling API: RefreshSystemApi.refresh_system_post ...'
36
+ end
37
+ # verify the required parameter 'refresh_system' is set
38
+ if @api_client.config.client_side_validation && refresh_system.nil?
39
+ fail ArgumentError, "Missing the required parameter 'refresh_system' when calling RefreshSystemApi.refresh_system_post"
40
+ end
41
+ # resource path
42
+ local_var_path = '/refresh-system'
43
+
44
+ # query parameters
45
+ query_params = opts[:query_params] || {}
46
+
47
+ # header parameters
48
+ header_params = opts[:header_params] || {}
49
+ # HTTP header 'Accept' (if needed)
50
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
51
+ # HTTP header 'Content-Type'
52
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
53
+
54
+ # form parameters
55
+ form_params = opts[:form_params] || {}
56
+
57
+ # http body (model)
58
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(refresh_system)
59
+
60
+ # return_type
61
+ return_type = opts[:debug_return_type] || 'RefreshSystem'
62
+
63
+ # auth_names
64
+ auth_names = opts[:debug_auth_names] || ['bearerAuth']
65
+
66
+ new_options = opts.merge(
67
+ :operation => :"RefreshSystemApi.refresh_system_post",
68
+ :header_params => header_params,
69
+ :query_params => query_params,
70
+ :form_params => form_params,
71
+ :body => post_body,
72
+ :auth_names => auth_names,
73
+ :return_type => return_type
74
+ )
75
+
76
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
77
+ if @api_client.config.debugging
78
+ @api_client.config.logger.debug "API called: RefreshSystemApi#refresh_system_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
79
+ end
80
+ return data, status_code, headers
81
+ end
82
+ end
83
+ end
@@ -13,24 +13,24 @@ OpenAPI Generator version: 5.0.0
13
13
  require 'cgi'
14
14
 
15
15
  module AutosdeOpenapiClient
16
- class StorageHostVolumeMappingApi
16
+ class StorageHostsMappingApi
17
17
  attr_accessor :api_client
18
18
 
19
19
  def initialize(api_client = ApiClient.default)
20
20
  @api_client = api_client
21
21
  end
22
22
  # @param [Hash] opts the optional parameters
23
- # @return [Array<StorageHostVolumeMappingResponse>]
23
+ # @return [Array<StorageHostsMappingResponse>]
24
24
  def storage_hosts_mapping_get(opts = {})
25
25
  data, _status_code, _headers = storage_hosts_mapping_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<StorageHostVolumeMappingResponse>, Integer, Hash)>] Array<StorageHostVolumeMappingResponse> data, response status code and response headers
30
+ # @return [Array<(Array<StorageHostsMappingResponse>, Integer, Hash)>] Array<StorageHostsMappingResponse> data, response status code and response headers
31
31
  def storage_hosts_mapping_get_with_http_info(opts = {})
32
32
  if @api_client.config.debugging
33
- @api_client.config.logger.debug 'Calling API: StorageHostVolumeMappingApi.storage_hosts_mapping_get ...'
33
+ @api_client.config.logger.debug 'Calling API: StorageHostsMappingApi.storage_hosts_mapping_get ...'
34
34
  end
35
35
  # resource path
36
36
  local_var_path = '/storage-hosts-mapping'
@@ -50,13 +50,13 @@ module AutosdeOpenapiClient
50
50
  post_body = opts[:debug_body]
51
51
 
52
52
  # return_type
53
- return_type = opts[:debug_return_type] || 'Array<StorageHostVolumeMappingResponse>'
53
+ return_type = opts[:debug_return_type] || 'Array<StorageHostsMappingResponse>'
54
54
 
55
55
  # auth_names
56
56
  auth_names = opts[:debug_auth_names] || ['bearerAuth']
57
57
 
58
58
  new_options = opts.merge(
59
- :operation => :"StorageHostVolumeMappingApi.storage_hosts_mapping_get",
59
+ :operation => :"StorageHostsMappingApi.storage_hosts_mapping_get",
60
60
  :header_params => header_params,
61
61
  :query_params => query_params,
62
62
  :form_params => form_params,
@@ -67,14 +67,14 @@ module AutosdeOpenapiClient
67
67
 
68
68
  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
69
69
  if @api_client.config.debugging
70
- @api_client.config.logger.debug "API called: StorageHostVolumeMappingApi#storage_hosts_mapping_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
70
+ @api_client.config.logger.debug "API called: StorageHostsMappingApi#storage_hosts_mapping_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
71
71
  end
72
72
  return data, status_code, headers
73
73
  end
74
74
 
75
75
  # @param pk [Integer]
76
76
  # @param [Hash] opts the optional parameters
77
- # @return [Array<StorageHostVolumeMappingResponse>]
77
+ # @return [Array<StorageHostsMappingResponse>]
78
78
  def storage_hosts_mapping_pk_delete(pk, opts = {})
79
79
  data, _status_code, _headers = storage_hosts_mapping_pk_delete_with_http_info(pk, opts)
80
80
  data
@@ -82,14 +82,14 @@ module AutosdeOpenapiClient
82
82
 
83
83
  # @param pk [Integer]
84
84
  # @param [Hash] opts the optional parameters
85
- # @return [Array<(Array<StorageHostVolumeMappingResponse>, Integer, Hash)>] Array<StorageHostVolumeMappingResponse> data, response status code and response headers
85
+ # @return [Array<(Array<StorageHostsMappingResponse>, Integer, Hash)>] Array<StorageHostsMappingResponse> data, response status code and response headers
86
86
  def storage_hosts_mapping_pk_delete_with_http_info(pk, opts = {})
87
87
  if @api_client.config.debugging
88
- @api_client.config.logger.debug 'Calling API: StorageHostVolumeMappingApi.storage_hosts_mapping_pk_delete ...'
88
+ @api_client.config.logger.debug 'Calling API: StorageHostsMappingApi.storage_hosts_mapping_pk_delete ...'
89
89
  end
90
90
  # verify the required parameter 'pk' is set
91
91
  if @api_client.config.client_side_validation && pk.nil?
92
- fail ArgumentError, "Missing the required parameter 'pk' when calling StorageHostVolumeMappingApi.storage_hosts_mapping_pk_delete"
92
+ fail ArgumentError, "Missing the required parameter 'pk' when calling StorageHostsMappingApi.storage_hosts_mapping_pk_delete"
93
93
  end
94
94
  # resource path
95
95
  local_var_path = '/storage-hosts-mapping/{pk}'.sub('{' + 'pk' + '}', CGI.escape(pk.to_s))
@@ -109,13 +109,13 @@ module AutosdeOpenapiClient
109
109
  post_body = opts[:debug_body]
110
110
 
111
111
  # return_type
112
- return_type = opts[:debug_return_type] || 'Array<StorageHostVolumeMappingResponse>'
112
+ return_type = opts[:debug_return_type] || 'Array<StorageHostsMappingResponse>'
113
113
 
114
114
  # auth_names
115
115
  auth_names = opts[:debug_auth_names] || ['bearerAuth']
116
116
 
117
117
  new_options = opts.merge(
118
- :operation => :"StorageHostVolumeMappingApi.storage_hosts_mapping_pk_delete",
118
+ :operation => :"StorageHostsMappingApi.storage_hosts_mapping_pk_delete",
119
119
  :header_params => header_params,
120
120
  :query_params => query_params,
121
121
  :form_params => form_params,
@@ -126,14 +126,14 @@ module AutosdeOpenapiClient
126
126
 
127
127
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
128
128
  if @api_client.config.debugging
129
- @api_client.config.logger.debug "API called: StorageHostVolumeMappingApi#storage_hosts_mapping_pk_delete\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
129
+ @api_client.config.logger.debug "API called: StorageHostsMappingApi#storage_hosts_mapping_pk_delete\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
130
130
  end
131
131
  return data, status_code, headers
132
132
  end
133
133
 
134
134
  # @param pk [Integer]
135
135
  # @param [Hash] opts the optional parameters
136
- # @return [Array<StorageHostVolumeMappingResponse>]
136
+ # @return [Array<StorageHostsMappingResponse>]
137
137
  def storage_hosts_mapping_pk_get(pk, opts = {})
138
138
  data, _status_code, _headers = storage_hosts_mapping_pk_get_with_http_info(pk, opts)
139
139
  data
@@ -141,14 +141,14 @@ module AutosdeOpenapiClient
141
141
 
142
142
  # @param pk [Integer]
143
143
  # @param [Hash] opts the optional parameters
144
- # @return [Array<(Array<StorageHostVolumeMappingResponse>, Integer, Hash)>] Array<StorageHostVolumeMappingResponse> data, response status code and response headers
144
+ # @return [Array<(Array<StorageHostsMappingResponse>, Integer, Hash)>] Array<StorageHostsMappingResponse> data, response status code and response headers
145
145
  def storage_hosts_mapping_pk_get_with_http_info(pk, opts = {})
146
146
  if @api_client.config.debugging
147
- @api_client.config.logger.debug 'Calling API: StorageHostVolumeMappingApi.storage_hosts_mapping_pk_get ...'
147
+ @api_client.config.logger.debug 'Calling API: StorageHostsMappingApi.storage_hosts_mapping_pk_get ...'
148
148
  end
149
149
  # verify the required parameter 'pk' is set
150
150
  if @api_client.config.client_side_validation && pk.nil?
151
- fail ArgumentError, "Missing the required parameter 'pk' when calling StorageHostVolumeMappingApi.storage_hosts_mapping_pk_get"
151
+ fail ArgumentError, "Missing the required parameter 'pk' when calling StorageHostsMappingApi.storage_hosts_mapping_pk_get"
152
152
  end
153
153
  # resource path
154
154
  local_var_path = '/storage-hosts-mapping/{pk}'.sub('{' + 'pk' + '}', CGI.escape(pk.to_s))
@@ -168,13 +168,13 @@ module AutosdeOpenapiClient
168
168
  post_body = opts[:debug_body]
169
169
 
170
170
  # return_type
171
- return_type = opts[:debug_return_type] || 'Array<StorageHostVolumeMappingResponse>'
171
+ return_type = opts[:debug_return_type] || 'Array<StorageHostsMappingResponse>'
172
172
 
173
173
  # auth_names
174
174
  auth_names = opts[:debug_auth_names] || ['bearerAuth']
175
175
 
176
176
  new_options = opts.merge(
177
- :operation => :"StorageHostVolumeMappingApi.storage_hosts_mapping_pk_get",
177
+ :operation => :"StorageHostsMappingApi.storage_hosts_mapping_pk_get",
178
178
  :header_params => header_params,
179
179
  :query_params => query_params,
180
180
  :form_params => form_params,
@@ -185,29 +185,29 @@ module AutosdeOpenapiClient
185
185
 
186
186
  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
187
187
  if @api_client.config.debugging
188
- @api_client.config.logger.debug "API called: StorageHostVolumeMappingApi#storage_hosts_mapping_pk_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
188
+ @api_client.config.logger.debug "API called: StorageHostsMappingApi#storage_hosts_mapping_pk_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
189
189
  end
190
190
  return data, status_code, headers
191
191
  end
192
192
 
193
- # @param storage_host_volume_mapping_create [StorageHostVolumeMappingCreate]
193
+ # @param storage_hosts_mapping_create [StorageHostsMappingCreate]
194
194
  # @param [Hash] opts the optional parameters
195
- # @return [StorageHostVolumeMapping]
196
- def storage_hosts_mapping_post(storage_host_volume_mapping_create, opts = {})
197
- data, _status_code, _headers = storage_hosts_mapping_post_with_http_info(storage_host_volume_mapping_create, opts)
195
+ # @return [StorageHostsMapping]
196
+ def storage_hosts_mapping_post(storage_hosts_mapping_create, opts = {})
197
+ data, _status_code, _headers = storage_hosts_mapping_post_with_http_info(storage_hosts_mapping_create, opts)
198
198
  data
199
199
  end
200
200
 
201
- # @param storage_host_volume_mapping_create [StorageHostVolumeMappingCreate]
201
+ # @param storage_hosts_mapping_create [StorageHostsMappingCreate]
202
202
  # @param [Hash] opts the optional parameters
203
- # @return [Array<(StorageHostVolumeMapping, Integer, Hash)>] StorageHostVolumeMapping data, response status code and response headers
204
- def storage_hosts_mapping_post_with_http_info(storage_host_volume_mapping_create, opts = {})
203
+ # @return [Array<(StorageHostsMapping, Integer, Hash)>] StorageHostsMapping data, response status code and response headers
204
+ def storage_hosts_mapping_post_with_http_info(storage_hosts_mapping_create, opts = {})
205
205
  if @api_client.config.debugging
206
- @api_client.config.logger.debug 'Calling API: StorageHostVolumeMappingApi.storage_hosts_mapping_post ...'
206
+ @api_client.config.logger.debug 'Calling API: StorageHostsMappingApi.storage_hosts_mapping_post ...'
207
207
  end
208
- # verify the required parameter 'storage_host_volume_mapping_create' is set
209
- if @api_client.config.client_side_validation && storage_host_volume_mapping_create.nil?
210
- fail ArgumentError, "Missing the required parameter 'storage_host_volume_mapping_create' when calling StorageHostVolumeMappingApi.storage_hosts_mapping_post"
208
+ # verify the required parameter 'storage_hosts_mapping_create' is set
209
+ if @api_client.config.client_side_validation && storage_hosts_mapping_create.nil?
210
+ fail ArgumentError, "Missing the required parameter 'storage_hosts_mapping_create' when calling StorageHostsMappingApi.storage_hosts_mapping_post"
211
211
  end
212
212
  # resource path
213
213
  local_var_path = '/storage-hosts-mapping'
@@ -226,16 +226,16 @@ module AutosdeOpenapiClient
226
226
  form_params = opts[:form_params] || {}
227
227
 
228
228
  # http body (model)
229
- post_body = opts[:debug_body] || @api_client.object_to_http_body(storage_host_volume_mapping_create)
229
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(storage_hosts_mapping_create)
230
230
 
231
231
  # return_type
232
- return_type = opts[:debug_return_type] || 'StorageHostVolumeMapping'
232
+ return_type = opts[:debug_return_type] || 'StorageHostsMapping'
233
233
 
234
234
  # auth_names
235
235
  auth_names = opts[:debug_auth_names] || ['bearerAuth']
236
236
 
237
237
  new_options = opts.merge(
238
- :operation => :"StorageHostVolumeMappingApi.storage_hosts_mapping_post",
238
+ :operation => :"StorageHostsMappingApi.storage_hosts_mapping_post",
239
239
  :header_params => header_params,
240
240
  :query_params => query_params,
241
241
  :form_params => form_params,
@@ -246,7 +246,7 @@ module AutosdeOpenapiClient
246
246
 
247
247
  data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
248
248
  if @api_client.config.debugging
249
- @api_client.config.logger.debug "API called: StorageHostVolumeMappingApi#storage_hosts_mapping_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
249
+ @api_client.config.logger.debug "API called: StorageHostsMappingApi#storage_hosts_mapping_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
250
250
  end
251
251
  return data, status_code, headers
252
252
  end
@@ -0,0 +1,230 @@
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
+ # CeleryBeatConfig object represents celery-beat (refresh params
18
+ class CeleryConfig
19
+ # celery_beat_enabled
20
+ attr_accessor :celery_beat_enabled
21
+
22
+ # interval_sec
23
+ attr_accessor :interval_sec
24
+
25
+ # Attribute mapping from ruby-style variable name to JSON key.
26
+ def self.attribute_map
27
+ {
28
+ :'celery_beat_enabled' => :'celery_beat_enabled',
29
+ :'interval_sec' => :'interval_sec'
30
+ }
31
+ end
32
+
33
+ # Returns all the JSON keys this model knows about
34
+ def self.acceptable_attributes
35
+ attribute_map.values
36
+ end
37
+
38
+ # Attribute type mapping.
39
+ def self.openapi_types
40
+ {
41
+ :'celery_beat_enabled' => :'Boolean',
42
+ :'interval_sec' => :'Integer'
43
+ }
44
+ end
45
+
46
+ # List of attributes with nullable: true
47
+ def self.openapi_nullable
48
+ Set.new([
49
+ ])
50
+ end
51
+
52
+ # Initializes the object
53
+ # @param [Hash] attributes Model attributes in the form of hash
54
+ def initialize(attributes = {})
55
+ if (!attributes.is_a?(Hash))
56
+ fail ArgumentError, "The input argument (attributes) must be a hash in `AutosdeOpenapiClient::CeleryConfig` initialize method"
57
+ end
58
+
59
+ # check to see if the attribute exists and convert string to symbol for hash key
60
+ attributes = attributes.each_with_object({}) { |(k, v), h|
61
+ if (!self.class.attribute_map.key?(k.to_sym))
62
+ fail ArgumentError, "`#{k}` is not a valid attribute in `AutosdeOpenapiClient::CeleryConfig`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
63
+ end
64
+ h[k.to_sym] = v
65
+ }
66
+
67
+ if attributes.key?(:'celery_beat_enabled')
68
+ self.celery_beat_enabled = attributes[:'celery_beat_enabled']
69
+ end
70
+
71
+ if attributes.key?(:'interval_sec')
72
+ self.interval_sec = attributes[:'interval_sec']
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
+ invalid_properties
81
+ end
82
+
83
+ # Check to see if the all the properties in the model are valid
84
+ # @return true if the model is valid
85
+ def valid?
86
+ true
87
+ end
88
+
89
+ # Checks equality by comparing each attribute.
90
+ # @param [Object] Object to be compared
91
+ def ==(o)
92
+ return true if self.equal?(o)
93
+ self.class == o.class &&
94
+ celery_beat_enabled == o.celery_beat_enabled &&
95
+ interval_sec == o.interval_sec
96
+ end
97
+
98
+ # @see the `==` method
99
+ # @param [Object] Object to be compared
100
+ def eql?(o)
101
+ self == o
102
+ end
103
+
104
+ # Calculates hash code according to all attributes.
105
+ # @return [Integer] Hash code
106
+ def hash
107
+ [celery_beat_enabled, interval_sec].hash
108
+ end
109
+
110
+ # Builds the object from hash
111
+ # @param [Hash] attributes Model attributes in the form of hash
112
+ # @return [Object] Returns the model itself
113
+ def self.build_from_hash(attributes)
114
+ new.build_from_hash(attributes)
115
+ end
116
+
117
+ # Builds the object from hash
118
+ # @param [Hash] attributes Model attributes in the form of hash
119
+ # @return [Object] Returns the model itself
120
+ def build_from_hash(attributes)
121
+ return nil unless attributes.is_a?(Hash)
122
+ self.class.openapi_types.each_pair do |key, type|
123
+ if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
124
+ self.send("#{key}=", nil)
125
+ elsif type =~ /\AArray<(.*)>/i
126
+ # check to ensure the input is an array given that the attribute
127
+ # is documented as an array but the input is not
128
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
129
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
130
+ end
131
+ elsif !attributes[self.class.attribute_map[key]].nil?
132
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
133
+ end
134
+ end
135
+
136
+ self
137
+ end
138
+
139
+ # Deserializes the data based on type
140
+ # @param string type Data type
141
+ # @param string value Value to be deserialized
142
+ # @return [Object] Deserialized data
143
+ def _deserialize(type, value)
144
+ case type.to_sym
145
+ when :Time
146
+ Time.parse(value)
147
+ when :Date
148
+ Date.parse(value)
149
+ when :String
150
+ value.to_s
151
+ when :Integer
152
+ value.to_i
153
+ when :Float
154
+ value.to_f
155
+ when :Boolean
156
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
157
+ true
158
+ else
159
+ false
160
+ end
161
+ when :Object
162
+ # generic object (usually a Hash), return directly
163
+ value
164
+ when /\AArray<(?<inner_type>.+)>\z/
165
+ inner_type = Regexp.last_match[:inner_type]
166
+ value.map { |v| _deserialize(inner_type, v) }
167
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
168
+ k_type = Regexp.last_match[:k_type]
169
+ v_type = Regexp.last_match[:v_type]
170
+ {}.tap do |hash|
171
+ value.each do |k, v|
172
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
173
+ end
174
+ end
175
+ else # model
176
+ # models (e.g. Pet) or oneOf
177
+ klass = AutosdeOpenapiClient.const_get(type)
178
+ klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
179
+ end
180
+ end
181
+
182
+ # Returns the string representation of the object
183
+ # @return [String] String presentation of the object
184
+ def to_s
185
+ to_hash.to_s
186
+ end
187
+
188
+ # to_body is an alias to to_hash (backward compatibility)
189
+ # @return [Hash] Returns the object in the form of hash
190
+ def to_body
191
+ to_hash
192
+ end
193
+
194
+ # Returns the object in the form of hash
195
+ # @return [Hash] Returns the object in the form of hash
196
+ def to_hash
197
+ hash = {}
198
+ self.class.attribute_map.each_pair do |attr, param|
199
+ value = self.send(attr)
200
+ if value.nil?
201
+ is_nullable = self.class.openapi_nullable.include?(attr)
202
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
203
+ end
204
+
205
+ hash[param] = _to_hash(value)
206
+ end
207
+ hash
208
+ end
209
+
210
+ # Outputs non-array value in the form of hash
211
+ # For object, use to_hash. Otherwise, just return the value
212
+ # @param [Object] value Any valid value
213
+ # @return [Hash] Returns the value in the form of hash
214
+ def _to_hash(value)
215
+ if value.is_a?(Array)
216
+ value.compact.map { |v| _to_hash(v) }
217
+ elsif value.is_a?(Hash)
218
+ {}.tap do |hash|
219
+ value.each { |k, v| hash[k] = _to_hash(v) }
220
+ end
221
+ elsif value.respond_to? :to_hash
222
+ value.to_hash
223
+ else
224
+ value
225
+ end
226
+ end
227
+
228
+ end
229
+
230
+ end