pulp_container_client 1.0.0rc1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (102) hide show
  1. checksums.yaml +7 -0
  2. data/Gemfile +9 -0
  3. data/README.md +164 -0
  4. data/Rakefile +10 -0
  5. data/docs/AsyncOperationResponse.md +17 -0
  6. data/docs/ContainerBlob.md +25 -0
  7. data/docs/ContainerContainerDistribution.md +31 -0
  8. data/docs/ContainerContainerRemote.md +43 -0
  9. data/docs/ContainerContainerRepository.md +27 -0
  10. data/docs/ContainerManifest.md +33 -0
  11. data/docs/ContainerTag.md +25 -0
  12. data/docs/ContentBlobsApi.md +142 -0
  13. data/docs/ContentManifestsApi.md +142 -0
  14. data/docs/ContentSummary.md +21 -0
  15. data/docs/ContentTagsApi.md +144 -0
  16. data/docs/DistributionsContainerApi.md +362 -0
  17. data/docs/InlineResponse200.md +23 -0
  18. data/docs/InlineResponse2001.md +23 -0
  19. data/docs/InlineResponse2002.md +23 -0
  20. data/docs/InlineResponse2003.md +23 -0
  21. data/docs/InlineResponse2004.md +23 -0
  22. data/docs/InlineResponse2005.md +23 -0
  23. data/docs/InlineResponse2006.md +23 -0
  24. data/docs/ManifestCopy.md +23 -0
  25. data/docs/RecursiveManage.md +17 -0
  26. data/docs/RemotesContainerApi.md +366 -0
  27. data/docs/RepositoriesContainerApi.md +739 -0
  28. data/docs/RepositoriesContainerVersionsApi.md +214 -0
  29. data/docs/RepositorySyncURL.md +19 -0
  30. data/docs/RepositoryVersion.md +25 -0
  31. data/docs/TagCopy.md +21 -0
  32. data/docs/TagImage.md +19 -0
  33. data/docs/UnTagImage.md +17 -0
  34. data/git_push.sh +58 -0
  35. data/lib/pulp_container_client/api/content_blobs_api.rb +176 -0
  36. data/lib/pulp_container_client/api/content_manifests_api.rb +176 -0
  37. data/lib/pulp_container_client/api/content_tags_api.rb +179 -0
  38. data/lib/pulp_container_client/api/distributions_container_api.rb +442 -0
  39. data/lib/pulp_container_client/api/remotes_container_api.rb +448 -0
  40. data/lib/pulp_container_client/api/repositories_container_api.rb +906 -0
  41. data/lib/pulp_container_client/api/repositories_container_versions_api.rb +268 -0
  42. data/lib/pulp_container_client/api_client.rb +402 -0
  43. data/lib/pulp_container_client/api_error.rb +57 -0
  44. data/lib/pulp_container_client/configuration.rb +243 -0
  45. data/lib/pulp_container_client/models/async_operation_response.rb +212 -0
  46. data/lib/pulp_container_client/models/container_blob.rb +299 -0
  47. data/lib/pulp_container_client/models/container_container_distribution.rb +342 -0
  48. data/lib/pulp_container_client/models/container_container_remote.rb +526 -0
  49. data/lib/pulp_container_client/models/container_container_repository.rb +294 -0
  50. data/lib/pulp_container_client/models/container_manifest.rb +363 -0
  51. data/lib/pulp_container_client/models/container_tag.rb +280 -0
  52. data/lib/pulp_container_client/models/content_summary.rb +246 -0
  53. data/lib/pulp_container_client/models/inline_response200.rb +247 -0
  54. data/lib/pulp_container_client/models/inline_response2001.rb +247 -0
  55. data/lib/pulp_container_client/models/inline_response2002.rb +247 -0
  56. data/lib/pulp_container_client/models/inline_response2003.rb +247 -0
  57. data/lib/pulp_container_client/models/inline_response2004.rb +247 -0
  58. data/lib/pulp_container_client/models/inline_response2005.rb +247 -0
  59. data/lib/pulp_container_client/models/inline_response2006.rb +247 -0
  60. data/lib/pulp_container_client/models/manifest_copy.rb +263 -0
  61. data/lib/pulp_container_client/models/recursive_manage.rb +209 -0
  62. data/lib/pulp_container_client/models/repository_sync_url.rb +224 -0
  63. data/lib/pulp_container_client/models/repository_version.rb +244 -0
  64. data/lib/pulp_container_client/models/tag_copy.rb +229 -0
  65. data/lib/pulp_container_client/models/tag_image.rb +265 -0
  66. data/lib/pulp_container_client/models/un_tag_image.rb +231 -0
  67. data/lib/pulp_container_client/version.rb +15 -0
  68. data/lib/pulp_container_client.rb +68 -0
  69. data/pulp_container_client.gemspec +39 -0
  70. data/spec/api/content_blobs_api_spec.rb +70 -0
  71. data/spec/api/content_manifests_api_spec.rb +70 -0
  72. data/spec/api/content_tags_api_spec.rb +71 -0
  73. data/spec/api/distributions_container_api_spec.rb +120 -0
  74. data/spec/api/remotes_container_api_spec.rb +122 -0
  75. data/spec/api/repositories_container_api_spec.rb +200 -0
  76. data/spec/api/repositories_container_versions_api_spec.rb +91 -0
  77. data/spec/api_client_spec.rb +188 -0
  78. data/spec/configuration_spec.rb +42 -0
  79. data/spec/models/async_operation_response_spec.rb +41 -0
  80. data/spec/models/container_blob_spec.rb +65 -0
  81. data/spec/models/container_container_distribution_spec.rb +83 -0
  82. data/spec/models/container_container_remote_spec.rb +123 -0
  83. data/spec/models/container_container_repository_spec.rb +71 -0
  84. data/spec/models/container_manifest_spec.rb +89 -0
  85. data/spec/models/container_tag_spec.rb +65 -0
  86. data/spec/models/content_summary_spec.rb +53 -0
  87. data/spec/models/inline_response2001_spec.rb +59 -0
  88. data/spec/models/inline_response2002_spec.rb +59 -0
  89. data/spec/models/inline_response2003_spec.rb +59 -0
  90. data/spec/models/inline_response2004_spec.rb +59 -0
  91. data/spec/models/inline_response2005_spec.rb +59 -0
  92. data/spec/models/inline_response2006_spec.rb +59 -0
  93. data/spec/models/inline_response200_spec.rb +59 -0
  94. data/spec/models/manifest_copy_spec.rb +63 -0
  95. data/spec/models/recursive_manage_spec.rb +41 -0
  96. data/spec/models/repository_sync_url_spec.rb +47 -0
  97. data/spec/models/repository_version_spec.rb +65 -0
  98. data/spec/models/tag_copy_spec.rb +53 -0
  99. data/spec/models/tag_image_spec.rb +47 -0
  100. data/spec/models/un_tag_image_spec.rb +41 -0
  101. data/spec/spec_helper.rb +111 -0
  102. metadata +230 -0
@@ -0,0 +1,442 @@
1
+ =begin
2
+ #Pulp 3 API
3
+
4
+ #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5
+
6
+ The version of the OpenAPI document: v3
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 4.2.2-SNAPSHOT
10
+
11
+ =end
12
+
13
+ require 'cgi'
14
+
15
+ module PulpContainerClient
16
+ class DistributionsContainerApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+ # Create a container distribution
23
+ # Trigger an asynchronous create task
24
+ # @param data [ContainerContainerDistribution]
25
+ # @param [Hash] opts the optional parameters
26
+ # @return [AsyncOperationResponse]
27
+ def create(data, opts = {})
28
+ data, _status_code, _headers = create_with_http_info(data, opts)
29
+ data
30
+ end
31
+
32
+ # Create a container distribution
33
+ # Trigger an asynchronous create task
34
+ # @param data [ContainerContainerDistribution]
35
+ # @param [Hash] opts the optional parameters
36
+ # @return [Array<(AsyncOperationResponse, Integer, Hash)>] AsyncOperationResponse data, response status code and response headers
37
+ def create_with_http_info(data, opts = {})
38
+ if @api_client.config.debugging
39
+ @api_client.config.logger.debug 'Calling API: DistributionsContainerApi.create ...'
40
+ end
41
+ # verify the required parameter 'data' is set
42
+ if @api_client.config.client_side_validation && data.nil?
43
+ fail ArgumentError, "Missing the required parameter 'data' when calling DistributionsContainerApi.create"
44
+ end
45
+ # resource path
46
+ local_var_path = '/pulp/api/v3/distributions/container/container/'
47
+
48
+ # query parameters
49
+ query_params = opts[:query_params] || {}
50
+
51
+ # header parameters
52
+ header_params = opts[:header_params] || {}
53
+ # HTTP header 'Accept' (if needed)
54
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
55
+ # HTTP header 'Content-Type'
56
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
57
+
58
+ # form parameters
59
+ form_params = opts[:form_params] || {}
60
+
61
+ # http body (model)
62
+ post_body = opts[:body] || @api_client.object_to_http_body(data)
63
+
64
+ # return_type
65
+ return_type = opts[:return_type] || 'AsyncOperationResponse'
66
+
67
+ # auth_names
68
+ auth_names = opts[:auth_names] || ['Basic']
69
+
70
+ new_options = opts.merge(
71
+ :header_params => header_params,
72
+ :query_params => query_params,
73
+ :form_params => form_params,
74
+ :body => post_body,
75
+ :auth_names => auth_names,
76
+ :return_type => return_type
77
+ )
78
+
79
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
80
+ if @api_client.config.debugging
81
+ @api_client.config.logger.debug "API called: DistributionsContainerApi#create\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
82
+ end
83
+ return data, status_code, headers
84
+ end
85
+
86
+ # Delete a container distribution
87
+ # Trigger an asynchronous delete task
88
+ # @param container_distribution_href [String] URI of Container Distribution. e.g.: /pulp/api/v3/distributions/container/container/1/
89
+ # @param [Hash] opts the optional parameters
90
+ # @return [AsyncOperationResponse]
91
+ def delete(container_distribution_href, opts = {})
92
+ data, _status_code, _headers = delete_with_http_info(container_distribution_href, opts)
93
+ data
94
+ end
95
+
96
+ # Delete a container distribution
97
+ # Trigger an asynchronous delete task
98
+ # @param container_distribution_href [String] URI of Container Distribution. e.g.: /pulp/api/v3/distributions/container/container/1/
99
+ # @param [Hash] opts the optional parameters
100
+ # @return [Array<(AsyncOperationResponse, Integer, Hash)>] AsyncOperationResponse data, response status code and response headers
101
+ def delete_with_http_info(container_distribution_href, opts = {})
102
+ if @api_client.config.debugging
103
+ @api_client.config.logger.debug 'Calling API: DistributionsContainerApi.delete ...'
104
+ end
105
+ # verify the required parameter 'container_distribution_href' is set
106
+ if @api_client.config.client_side_validation && container_distribution_href.nil?
107
+ fail ArgumentError, "Missing the required parameter 'container_distribution_href' when calling DistributionsContainerApi.delete"
108
+ end
109
+ # resource path
110
+ local_var_path = '{container_distribution_href}'.sub('{' + 'container_distribution_href' + '}', CGI.escape(container_distribution_href.to_s).gsub('%2F', '/'))
111
+
112
+ # query parameters
113
+ query_params = opts[:query_params] || {}
114
+
115
+ # header parameters
116
+ header_params = opts[:header_params] || {}
117
+ # HTTP header 'Accept' (if needed)
118
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
119
+
120
+ # form parameters
121
+ form_params = opts[:form_params] || {}
122
+
123
+ # http body (model)
124
+ post_body = opts[:body]
125
+
126
+ # return_type
127
+ return_type = opts[:return_type] || 'AsyncOperationResponse'
128
+
129
+ # auth_names
130
+ auth_names = opts[:auth_names] || ['Basic']
131
+
132
+ new_options = opts.merge(
133
+ :header_params => header_params,
134
+ :query_params => query_params,
135
+ :form_params => form_params,
136
+ :body => post_body,
137
+ :auth_names => auth_names,
138
+ :return_type => return_type
139
+ )
140
+
141
+ data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
142
+ if @api_client.config.debugging
143
+ @api_client.config.logger.debug "API called: DistributionsContainerApi#delete\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
144
+ end
145
+ return data, status_code, headers
146
+ end
147
+
148
+ # List container distributions
149
+ # The Container Distribution will serve the latest version of a Repository if ``repository`` is specified. The Container Distribution will serve a specific repository version if ``repository_version``. Note that **either** ``repository`` or ``repository_version`` can be set on a Container Distribution, but not both.
150
+ # @param [Hash] opts the optional parameters
151
+ # @option opts [String] :name
152
+ # @option opts [String] :name__in Filter results where name is in a comma-separated list of values
153
+ # @option opts [String] :base_path
154
+ # @option opts [String] :base_path__contains Filter results where base_path contains value
155
+ # @option opts [String] :base_path__icontains Filter results where base_path contains value
156
+ # @option opts [String] :base_path__in Filter results where base_path is in a comma-separated list of values
157
+ # @option opts [Integer] :limit Number of results to return per page.
158
+ # @option opts [Integer] :offset The initial index from which to return the results.
159
+ # @option opts [String] :fields A list of fields to include in the response.
160
+ # @option opts [String] :exclude_fields A list of fields to exclude from the response.
161
+ # @return [InlineResponse2003]
162
+ def list(opts = {})
163
+ data, _status_code, _headers = list_with_http_info(opts)
164
+ data
165
+ end
166
+
167
+ # List container distributions
168
+ # The Container Distribution will serve the latest version of a Repository if &#x60;&#x60;repository&#x60;&#x60; is specified. The Container Distribution will serve a specific repository version if &#x60;&#x60;repository_version&#x60;&#x60;. Note that **either** &#x60;&#x60;repository&#x60;&#x60; or &#x60;&#x60;repository_version&#x60;&#x60; can be set on a Container Distribution, but not both.
169
+ # @param [Hash] opts the optional parameters
170
+ # @option opts [String] :name
171
+ # @option opts [String] :name__in Filter results where name is in a comma-separated list of values
172
+ # @option opts [String] :base_path
173
+ # @option opts [String] :base_path__contains Filter results where base_path contains value
174
+ # @option opts [String] :base_path__icontains Filter results where base_path contains value
175
+ # @option opts [String] :base_path__in Filter results where base_path is in a comma-separated list of values
176
+ # @option opts [Integer] :limit Number of results to return per page.
177
+ # @option opts [Integer] :offset The initial index from which to return the results.
178
+ # @option opts [String] :fields A list of fields to include in the response.
179
+ # @option opts [String] :exclude_fields A list of fields to exclude from the response.
180
+ # @return [Array<(InlineResponse2003, Integer, Hash)>] InlineResponse2003 data, response status code and response headers
181
+ def list_with_http_info(opts = {})
182
+ if @api_client.config.debugging
183
+ @api_client.config.logger.debug 'Calling API: DistributionsContainerApi.list ...'
184
+ end
185
+ # resource path
186
+ local_var_path = '/pulp/api/v3/distributions/container/container/'
187
+
188
+ # query parameters
189
+ query_params = opts[:query_params] || {}
190
+ query_params[:'name'] = opts[:'name'] if !opts[:'name'].nil?
191
+ query_params[:'name__in'] = opts[:'name__in'] if !opts[:'name__in'].nil?
192
+ query_params[:'base_path'] = opts[:'base_path'] if !opts[:'base_path'].nil?
193
+ query_params[:'base_path__contains'] = opts[:'base_path__contains'] if !opts[:'base_path__contains'].nil?
194
+ query_params[:'base_path__icontains'] = opts[:'base_path__icontains'] if !opts[:'base_path__icontains'].nil?
195
+ query_params[:'base_path__in'] = opts[:'base_path__in'] if !opts[:'base_path__in'].nil?
196
+ query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
197
+ query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
198
+ query_params[:'fields'] = opts[:'fields'] if !opts[:'fields'].nil?
199
+ query_params[:'exclude_fields'] = opts[:'exclude_fields'] if !opts[:'exclude_fields'].nil?
200
+
201
+ # header parameters
202
+ header_params = opts[:header_params] || {}
203
+ # HTTP header 'Accept' (if needed)
204
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
205
+
206
+ # form parameters
207
+ form_params = opts[:form_params] || {}
208
+
209
+ # http body (model)
210
+ post_body = opts[:body]
211
+
212
+ # return_type
213
+ return_type = opts[:return_type] || 'InlineResponse2003'
214
+
215
+ # auth_names
216
+ auth_names = opts[:auth_names] || ['Basic']
217
+
218
+ new_options = opts.merge(
219
+ :header_params => header_params,
220
+ :query_params => query_params,
221
+ :form_params => form_params,
222
+ :body => post_body,
223
+ :auth_names => auth_names,
224
+ :return_type => return_type
225
+ )
226
+
227
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
228
+ if @api_client.config.debugging
229
+ @api_client.config.logger.debug "API called: DistributionsContainerApi#list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
230
+ end
231
+ return data, status_code, headers
232
+ end
233
+
234
+ # Partially update a container distribution
235
+ # Trigger an asynchronous partial update task
236
+ # @param container_distribution_href [String] URI of Container Distribution. e.g.: /pulp/api/v3/distributions/container/container/1/
237
+ # @param data [ContainerContainerDistribution]
238
+ # @param [Hash] opts the optional parameters
239
+ # @return [AsyncOperationResponse]
240
+ def partial_update(container_distribution_href, data, opts = {})
241
+ data, _status_code, _headers = partial_update_with_http_info(container_distribution_href, data, opts)
242
+ data
243
+ end
244
+
245
+ # Partially update a container distribution
246
+ # Trigger an asynchronous partial update task
247
+ # @param container_distribution_href [String] URI of Container Distribution. e.g.: /pulp/api/v3/distributions/container/container/1/
248
+ # @param data [ContainerContainerDistribution]
249
+ # @param [Hash] opts the optional parameters
250
+ # @return [Array<(AsyncOperationResponse, Integer, Hash)>] AsyncOperationResponse data, response status code and response headers
251
+ def partial_update_with_http_info(container_distribution_href, data, opts = {})
252
+ if @api_client.config.debugging
253
+ @api_client.config.logger.debug 'Calling API: DistributionsContainerApi.partial_update ...'
254
+ end
255
+ # verify the required parameter 'container_distribution_href' is set
256
+ if @api_client.config.client_side_validation && container_distribution_href.nil?
257
+ fail ArgumentError, "Missing the required parameter 'container_distribution_href' when calling DistributionsContainerApi.partial_update"
258
+ end
259
+ # verify the required parameter 'data' is set
260
+ if @api_client.config.client_side_validation && data.nil?
261
+ fail ArgumentError, "Missing the required parameter 'data' when calling DistributionsContainerApi.partial_update"
262
+ end
263
+ # resource path
264
+ local_var_path = '{container_distribution_href}'.sub('{' + 'container_distribution_href' + '}', CGI.escape(container_distribution_href.to_s).gsub('%2F', '/'))
265
+
266
+ # query parameters
267
+ query_params = opts[:query_params] || {}
268
+
269
+ # header parameters
270
+ header_params = opts[:header_params] || {}
271
+ # HTTP header 'Accept' (if needed)
272
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
273
+ # HTTP header 'Content-Type'
274
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
275
+
276
+ # form parameters
277
+ form_params = opts[:form_params] || {}
278
+
279
+ # http body (model)
280
+ post_body = opts[:body] || @api_client.object_to_http_body(data)
281
+
282
+ # return_type
283
+ return_type = opts[:return_type] || 'AsyncOperationResponse'
284
+
285
+ # auth_names
286
+ auth_names = opts[:auth_names] || ['Basic']
287
+
288
+ new_options = opts.merge(
289
+ :header_params => header_params,
290
+ :query_params => query_params,
291
+ :form_params => form_params,
292
+ :body => post_body,
293
+ :auth_names => auth_names,
294
+ :return_type => return_type
295
+ )
296
+
297
+ data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
298
+ if @api_client.config.debugging
299
+ @api_client.config.logger.debug "API called: DistributionsContainerApi#partial_update\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
300
+ end
301
+ return data, status_code, headers
302
+ end
303
+
304
+ # Inspect a container distribution
305
+ # The Container Distribution will serve the latest version of a Repository if ``repository`` is specified. The Container Distribution will serve a specific repository version if ``repository_version``. Note that **either** ``repository`` or ``repository_version`` can be set on a Container Distribution, but not both.
306
+ # @param container_distribution_href [String] URI of Container Distribution. e.g.: /pulp/api/v3/distributions/container/container/1/
307
+ # @param [Hash] opts the optional parameters
308
+ # @option opts [String] :fields A list of fields to include in the response.
309
+ # @option opts [String] :exclude_fields A list of fields to exclude from the response.
310
+ # @return [ContainerContainerDistribution]
311
+ def read(container_distribution_href, opts = {})
312
+ data, _status_code, _headers = read_with_http_info(container_distribution_href, opts)
313
+ data
314
+ end
315
+
316
+ # Inspect a container distribution
317
+ # The Container Distribution will serve the latest version of a Repository if &#x60;&#x60;repository&#x60;&#x60; is specified. The Container Distribution will serve a specific repository version if &#x60;&#x60;repository_version&#x60;&#x60;. Note that **either** &#x60;&#x60;repository&#x60;&#x60; or &#x60;&#x60;repository_version&#x60;&#x60; can be set on a Container Distribution, but not both.
318
+ # @param container_distribution_href [String] URI of Container Distribution. e.g.: /pulp/api/v3/distributions/container/container/1/
319
+ # @param [Hash] opts the optional parameters
320
+ # @option opts [String] :fields A list of fields to include in the response.
321
+ # @option opts [String] :exclude_fields A list of fields to exclude from the response.
322
+ # @return [Array<(ContainerContainerDistribution, Integer, Hash)>] ContainerContainerDistribution data, response status code and response headers
323
+ def read_with_http_info(container_distribution_href, opts = {})
324
+ if @api_client.config.debugging
325
+ @api_client.config.logger.debug 'Calling API: DistributionsContainerApi.read ...'
326
+ end
327
+ # verify the required parameter 'container_distribution_href' is set
328
+ if @api_client.config.client_side_validation && container_distribution_href.nil?
329
+ fail ArgumentError, "Missing the required parameter 'container_distribution_href' when calling DistributionsContainerApi.read"
330
+ end
331
+ # resource path
332
+ local_var_path = '{container_distribution_href}'.sub('{' + 'container_distribution_href' + '}', CGI.escape(container_distribution_href.to_s).gsub('%2F', '/'))
333
+
334
+ # query parameters
335
+ query_params = opts[:query_params] || {}
336
+ query_params[:'fields'] = opts[:'fields'] if !opts[:'fields'].nil?
337
+ query_params[:'exclude_fields'] = opts[:'exclude_fields'] if !opts[:'exclude_fields'].nil?
338
+
339
+ # header parameters
340
+ header_params = opts[:header_params] || {}
341
+ # HTTP header 'Accept' (if needed)
342
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
343
+
344
+ # form parameters
345
+ form_params = opts[:form_params] || {}
346
+
347
+ # http body (model)
348
+ post_body = opts[:body]
349
+
350
+ # return_type
351
+ return_type = opts[:return_type] || 'ContainerContainerDistribution'
352
+
353
+ # auth_names
354
+ auth_names = opts[:auth_names] || ['Basic']
355
+
356
+ new_options = opts.merge(
357
+ :header_params => header_params,
358
+ :query_params => query_params,
359
+ :form_params => form_params,
360
+ :body => post_body,
361
+ :auth_names => auth_names,
362
+ :return_type => return_type
363
+ )
364
+
365
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
366
+ if @api_client.config.debugging
367
+ @api_client.config.logger.debug "API called: DistributionsContainerApi#read\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
368
+ end
369
+ return data, status_code, headers
370
+ end
371
+
372
+ # Update a container distribution
373
+ # Trigger an asynchronous update task
374
+ # @param container_distribution_href [String] URI of Container Distribution. e.g.: /pulp/api/v3/distributions/container/container/1/
375
+ # @param data [ContainerContainerDistribution]
376
+ # @param [Hash] opts the optional parameters
377
+ # @return [AsyncOperationResponse]
378
+ def update(container_distribution_href, data, opts = {})
379
+ data, _status_code, _headers = update_with_http_info(container_distribution_href, data, opts)
380
+ data
381
+ end
382
+
383
+ # Update a container distribution
384
+ # Trigger an asynchronous update task
385
+ # @param container_distribution_href [String] URI of Container Distribution. e.g.: /pulp/api/v3/distributions/container/container/1/
386
+ # @param data [ContainerContainerDistribution]
387
+ # @param [Hash] opts the optional parameters
388
+ # @return [Array<(AsyncOperationResponse, Integer, Hash)>] AsyncOperationResponse data, response status code and response headers
389
+ def update_with_http_info(container_distribution_href, data, opts = {})
390
+ if @api_client.config.debugging
391
+ @api_client.config.logger.debug 'Calling API: DistributionsContainerApi.update ...'
392
+ end
393
+ # verify the required parameter 'container_distribution_href' is set
394
+ if @api_client.config.client_side_validation && container_distribution_href.nil?
395
+ fail ArgumentError, "Missing the required parameter 'container_distribution_href' when calling DistributionsContainerApi.update"
396
+ end
397
+ # verify the required parameter 'data' is set
398
+ if @api_client.config.client_side_validation && data.nil?
399
+ fail ArgumentError, "Missing the required parameter 'data' when calling DistributionsContainerApi.update"
400
+ end
401
+ # resource path
402
+ local_var_path = '{container_distribution_href}'.sub('{' + 'container_distribution_href' + '}', CGI.escape(container_distribution_href.to_s).gsub('%2F', '/'))
403
+
404
+ # query parameters
405
+ query_params = opts[:query_params] || {}
406
+
407
+ # header parameters
408
+ header_params = opts[:header_params] || {}
409
+ # HTTP header 'Accept' (if needed)
410
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
411
+ # HTTP header 'Content-Type'
412
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
413
+
414
+ # form parameters
415
+ form_params = opts[:form_params] || {}
416
+
417
+ # http body (model)
418
+ post_body = opts[:body] || @api_client.object_to_http_body(data)
419
+
420
+ # return_type
421
+ return_type = opts[:return_type] || 'AsyncOperationResponse'
422
+
423
+ # auth_names
424
+ auth_names = opts[:auth_names] || ['Basic']
425
+
426
+ new_options = opts.merge(
427
+ :header_params => header_params,
428
+ :query_params => query_params,
429
+ :form_params => form_params,
430
+ :body => post_body,
431
+ :auth_names => auth_names,
432
+ :return_type => return_type
433
+ )
434
+
435
+ data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
436
+ if @api_client.config.debugging
437
+ @api_client.config.logger.debug "API called: DistributionsContainerApi#update\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
438
+ end
439
+ return data, status_code, headers
440
+ end
441
+ end
442
+ end