pulp_file_client 1.11.1 → 1.11.3

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 (50) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +5 -4
  3. data/docs/AcsFileApi.md +18 -18
  4. data/docs/ContentFilesApi.md +8 -8
  5. data/docs/DistributionsFileApi.md +22 -20
  6. data/docs/FileFileDistribution.md +1 -1
  7. data/docs/FileFileDistributionResponse.md +1 -1
  8. data/docs/FileFileRemote.md +1 -1
  9. data/docs/FileFileRemoteResponse.md +4 -2
  10. data/docs/FileFileRemoteResponseHiddenFields.md +19 -0
  11. data/docs/FileFileRepository.md +1 -1
  12. data/docs/FileFileRepositoryResponse.md +1 -1
  13. data/docs/PatchedfileFileDistribution.md +1 -1
  14. data/docs/PatchedfileFileRemote.md +1 -1
  15. data/docs/PatchedfileFileRepository.md +1 -1
  16. data/docs/PublicationsFileApi.md +18 -18
  17. data/docs/RemotesFileApi.md +20 -20
  18. data/docs/RepositoriesFileApi.md +20 -18
  19. data/docs/RepositoriesFileVersionsApi.md +12 -12
  20. data/lib/pulp_file_client/api/acs_file_api.rb +27 -27
  21. data/lib/pulp_file_client/api/content_files_api.rb +13 -13
  22. data/lib/pulp_file_client/api/distributions_file_api.rb +32 -29
  23. data/lib/pulp_file_client/api/publications_file_api.rb +27 -27
  24. data/lib/pulp_file_client/api/remotes_file_api.rb +29 -29
  25. data/lib/pulp_file_client/api/repositories_file_api.rb +30 -27
  26. data/lib/pulp_file_client/api/repositories_file_versions_api.rb +17 -17
  27. data/lib/pulp_file_client/api_client.rb +1 -1
  28. data/lib/pulp_file_client/models/file_file_distribution.rb +4 -2
  29. data/lib/pulp_file_client/models/file_file_distribution_response.rb +4 -2
  30. data/lib/pulp_file_client/models/file_file_remote.rb +4 -2
  31. data/lib/pulp_file_client/models/file_file_remote_response.rb +21 -7
  32. data/lib/pulp_file_client/models/file_file_remote_response_hidden_fields.rb +215 -0
  33. data/lib/pulp_file_client/models/file_file_repository.rb +4 -2
  34. data/lib/pulp_file_client/models/file_file_repository_response.rb +4 -2
  35. data/lib/pulp_file_client/models/patchedfile_file_distribution.rb +4 -2
  36. data/lib/pulp_file_client/models/patchedfile_file_remote.rb +4 -2
  37. data/lib/pulp_file_client/models/patchedfile_file_repository.rb +4 -2
  38. data/lib/pulp_file_client/version.rb +1 -1
  39. data/lib/pulp_file_client.rb +1 -0
  40. data/pulp_file_client.gemspec +1 -1
  41. data/spec/api/acs_file_api_spec.rb +9 -9
  42. data/spec/api/content_files_api_spec.rb +4 -4
  43. data/spec/api/distributions_file_api_spec.rb +11 -10
  44. data/spec/api/publications_file_api_spec.rb +9 -9
  45. data/spec/api/remotes_file_api_spec.rb +10 -10
  46. data/spec/api/repositories_file_api_spec.rb +10 -9
  47. data/spec/api/repositories_file_versions_api_spec.rb +6 -6
  48. data/spec/models/file_file_remote_response_hidden_fields_spec.rb +47 -0
  49. data/spec/models/file_file_remote_response_spec.rb +6 -0
  50. metadata +39 -35
@@ -217,7 +217,7 @@ module PulpFileClient
217
217
  # FileRepository represents a single file repository, to which content can be synced, added, or removed.
218
218
  # @param [Hash] opts the optional parameters
219
219
  # @option opts [Integer] :limit Number of results to return per page.
220
- # @option opts [String] :name
220
+ # @option opts [String] :name Filter results where name matches value
221
221
  # @option opts [String] :name__contains Filter results where name contains value
222
222
  # @option opts [String] :name__icontains Filter results where name contains value
223
223
  # @option opts [Array<String>] :name__in Filter results where name is in a comma-separated list of values
@@ -225,8 +225,9 @@ module PulpFileClient
225
225
  # @option opts [Integer] :offset The initial index from which to return the results.
226
226
  # @option opts [Array<String>] :ordering Ordering
227
227
  # @option opts [String] :pulp_label_select Filter labels by search string
228
- # @option opts [String] :fields A list of fields to include in the response.
229
- # @option opts [String] :exclude_fields A list of fields to exclude from the response.
228
+ # @option opts [String] :remote Foreign Key referenced by HREF
229
+ # @option opts [Array<String>] :fields A list of fields to include in the response.
230
+ # @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
230
231
  # @return [PaginatedfileFileRepositoryResponseList]
231
232
  def list(opts = {})
232
233
  data, _status_code, _headers = list_with_http_info(opts)
@@ -237,7 +238,7 @@ module PulpFileClient
237
238
  # FileRepository represents a single file repository, to which content can be synced, added, or removed.
238
239
  # @param [Hash] opts the optional parameters
239
240
  # @option opts [Integer] :limit Number of results to return per page.
240
- # @option opts [String] :name
241
+ # @option opts [String] :name Filter results where name matches value
241
242
  # @option opts [String] :name__contains Filter results where name contains value
242
243
  # @option opts [String] :name__icontains Filter results where name contains value
243
244
  # @option opts [Array<String>] :name__in Filter results where name is in a comma-separated list of values
@@ -245,14 +246,15 @@ module PulpFileClient
245
246
  # @option opts [Integer] :offset The initial index from which to return the results.
246
247
  # @option opts [Array<String>] :ordering Ordering
247
248
  # @option opts [String] :pulp_label_select Filter labels by search string
248
- # @option opts [String] :fields A list of fields to include in the response.
249
- # @option opts [String] :exclude_fields A list of fields to exclude from the response.
249
+ # @option opts [String] :remote Foreign Key referenced by HREF
250
+ # @option opts [Array<String>] :fields A list of fields to include in the response.
251
+ # @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
250
252
  # @return [Array<(PaginatedfileFileRepositoryResponseList, Integer, Hash)>] PaginatedfileFileRepositoryResponseList data, response status code and response headers
251
253
  def list_with_http_info(opts = {})
252
254
  if @api_client.config.debugging
253
255
  @api_client.config.logger.debug 'Calling API: RepositoriesFileApi.list ...'
254
256
  end
255
- allowable_values = ["-alternatecontentsourcepath", "-content", "-core_pulp_exporter", "-description", "-distributions", "-file_filerepository", "-group_roles", "-name", "-next_version", "-pk", "-pulp_created", "-pulp_id", "-pulp_labels", "-pulp_last_updated", "-pulp_type", "-pulpimporterrepository", "-remote", "-repositorycontent", "-retain_repo_versions", "-user_hidden", "-user_roles", "-versions", "alternatecontentsourcepath", "content", "core_pulp_exporter", "description", "distributions", "file_filerepository", "group_roles", "name", "next_version", "pk", "pulp_created", "pulp_id", "pulp_labels", "pulp_last_updated", "pulp_type", "pulpimporterrepository", "remote", "repositorycontent", "retain_repo_versions", "user_hidden", "user_roles", "versions"]
257
+ allowable_values = ["-description", "-name", "-next_version", "-pk", "-pulp_created", "-pulp_id", "-pulp_labels", "-pulp_last_updated", "-pulp_type", "-retain_repo_versions", "-user_hidden", "description", "name", "next_version", "pk", "pulp_created", "pulp_id", "pulp_labels", "pulp_last_updated", "pulp_type", "retain_repo_versions", "user_hidden"]
256
258
  if @api_client.config.client_side_validation && opts[:'ordering'] && !opts[:'ordering'].all? { |item| allowable_values.include?(item) }
257
259
  fail ArgumentError, "invalid value for \"ordering\", must include one of #{allowable_values}"
258
260
  end
@@ -270,8 +272,9 @@ module PulpFileClient
270
272
  query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
271
273
  query_params[:'ordering'] = @api_client.build_collection_param(opts[:'ordering'], :csv) if !opts[:'ordering'].nil?
272
274
  query_params[:'pulp_label_select'] = opts[:'pulp_label_select'] if !opts[:'pulp_label_select'].nil?
273
- query_params[:'fields'] = opts[:'fields'] if !opts[:'fields'].nil?
274
- query_params[:'exclude_fields'] = opts[:'exclude_fields'] if !opts[:'exclude_fields'].nil?
275
+ query_params[:'remote'] = opts[:'remote'] if !opts[:'remote'].nil?
276
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :multi) if !opts[:'fields'].nil?
277
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :multi) if !opts[:'exclude_fields'].nil?
275
278
 
276
279
  # header parameters
277
280
  header_params = opts[:header_params] || {}
@@ -309,8 +312,8 @@ module PulpFileClient
309
312
  # List roles assigned to this object.
310
313
  # @param file_file_repository_href [String]
311
314
  # @param [Hash] opts the optional parameters
312
- # @option opts [String] :fields A list of fields to include in the response.
313
- # @option opts [String] :exclude_fields A list of fields to exclude from the response.
315
+ # @option opts [Array<String>] :fields A list of fields to include in the response.
316
+ # @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
314
317
  # @return [ObjectRolesResponse]
315
318
  def list_roles(file_file_repository_href, opts = {})
316
319
  data, _status_code, _headers = list_roles_with_http_info(file_file_repository_href, opts)
@@ -320,8 +323,8 @@ module PulpFileClient
320
323
  # List roles assigned to this object.
321
324
  # @param file_file_repository_href [String]
322
325
  # @param [Hash] opts the optional parameters
323
- # @option opts [String] :fields A list of fields to include in the response.
324
- # @option opts [String] :exclude_fields A list of fields to exclude from the response.
326
+ # @option opts [Array<String>] :fields A list of fields to include in the response.
327
+ # @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
325
328
  # @return [Array<(ObjectRolesResponse, Integer, Hash)>] ObjectRolesResponse data, response status code and response headers
326
329
  def list_roles_with_http_info(file_file_repository_href, opts = {})
327
330
  if @api_client.config.debugging
@@ -336,8 +339,8 @@ module PulpFileClient
336
339
 
337
340
  # query parameters
338
341
  query_params = opts[:query_params] || {}
339
- query_params[:'fields'] = opts[:'fields'] if !opts[:'fields'].nil?
340
- query_params[:'exclude_fields'] = opts[:'exclude_fields'] if !opts[:'exclude_fields'].nil?
342
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :multi) if !opts[:'fields'].nil?
343
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :multi) if !opts[:'exclude_fields'].nil?
341
344
 
342
345
  # header parameters
343
346
  header_params = opts[:header_params] || {}
@@ -445,8 +448,8 @@ module PulpFileClient
445
448
  # List permissions available to the current user on this object.
446
449
  # @param file_file_repository_href [String]
447
450
  # @param [Hash] opts the optional parameters
448
- # @option opts [String] :fields A list of fields to include in the response.
449
- # @option opts [String] :exclude_fields A list of fields to exclude from the response.
451
+ # @option opts [Array<String>] :fields A list of fields to include in the response.
452
+ # @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
450
453
  # @return [MyPermissionsResponse]
451
454
  def my_permissions(file_file_repository_href, opts = {})
452
455
  data, _status_code, _headers = my_permissions_with_http_info(file_file_repository_href, opts)
@@ -456,8 +459,8 @@ module PulpFileClient
456
459
  # List permissions available to the current user on this object.
457
460
  # @param file_file_repository_href [String]
458
461
  # @param [Hash] opts the optional parameters
459
- # @option opts [String] :fields A list of fields to include in the response.
460
- # @option opts [String] :exclude_fields A list of fields to exclude from the response.
462
+ # @option opts [Array<String>] :fields A list of fields to include in the response.
463
+ # @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
461
464
  # @return [Array<(MyPermissionsResponse, Integer, Hash)>] MyPermissionsResponse data, response status code and response headers
462
465
  def my_permissions_with_http_info(file_file_repository_href, opts = {})
463
466
  if @api_client.config.debugging
@@ -472,8 +475,8 @@ module PulpFileClient
472
475
 
473
476
  # query parameters
474
477
  query_params = opts[:query_params] || {}
475
- query_params[:'fields'] = opts[:'fields'] if !opts[:'fields'].nil?
476
- query_params[:'exclude_fields'] = opts[:'exclude_fields'] if !opts[:'exclude_fields'].nil?
478
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :multi) if !opts[:'fields'].nil?
479
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :multi) if !opts[:'exclude_fields'].nil?
477
480
 
478
481
  # header parameters
479
482
  header_params = opts[:header_params] || {}
@@ -582,8 +585,8 @@ module PulpFileClient
582
585
  # FileRepository represents a single file repository, to which content can be synced, added, or removed.
583
586
  # @param file_file_repository_href [String]
584
587
  # @param [Hash] opts the optional parameters
585
- # @option opts [String] :fields A list of fields to include in the response.
586
- # @option opts [String] :exclude_fields A list of fields to exclude from the response.
588
+ # @option opts [Array<String>] :fields A list of fields to include in the response.
589
+ # @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
587
590
  # @return [FileFileRepositoryResponse]
588
591
  def read(file_file_repository_href, opts = {})
589
592
  data, _status_code, _headers = read_with_http_info(file_file_repository_href, opts)
@@ -594,8 +597,8 @@ module PulpFileClient
594
597
  # FileRepository represents a single file repository, to which content can be synced, added, or removed.
595
598
  # @param file_file_repository_href [String]
596
599
  # @param [Hash] opts the optional parameters
597
- # @option opts [String] :fields A list of fields to include in the response.
598
- # @option opts [String] :exclude_fields A list of fields to exclude from the response.
600
+ # @option opts [Array<String>] :fields A list of fields to include in the response.
601
+ # @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
599
602
  # @return [Array<(FileFileRepositoryResponse, Integer, Hash)>] FileFileRepositoryResponse data, response status code and response headers
600
603
  def read_with_http_info(file_file_repository_href, opts = {})
601
604
  if @api_client.config.debugging
@@ -610,8 +613,8 @@ module PulpFileClient
610
613
 
611
614
  # query parameters
612
615
  query_params = opts[:query_params] || {}
613
- query_params[:'fields'] = opts[:'fields'] if !opts[:'fields'].nil?
614
- query_params[:'exclude_fields'] = opts[:'exclude_fields'] if !opts[:'exclude_fields'].nil?
616
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :multi) if !opts[:'fields'].nil?
617
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :multi) if !opts[:'exclude_fields'].nil?
615
618
 
616
619
  # header parameters
617
620
  header_params = opts[:header_params] || {}
@@ -88,7 +88,7 @@ module PulpFileClient
88
88
  # @option opts [String] :content Content Unit referenced by HREF
89
89
  # @option opts [String] :content__in Content Unit referenced by HREF
90
90
  # @option opts [Integer] :limit Number of results to return per page.
91
- # @option opts [Integer] :number
91
+ # @option opts [Integer] :number Filter results where number matches value
92
92
  # @option opts [Integer] :number__gt Filter results where number is greater than value
93
93
  # @option opts [Integer] :number__gte Filter results where number is greater than or equal to value
94
94
  # @option opts [Integer] :number__lt Filter results where number is less than value
@@ -96,14 +96,14 @@ module PulpFileClient
96
96
  # @option opts [Array<Integer>] :number__range Filter results where number is between two comma separated values
97
97
  # @option opts [Integer] :offset The initial index from which to return the results.
98
98
  # @option opts [Array<String>] :ordering Ordering
99
- # @option opts [DateTime] :pulp_created ISO 8601 formatted dates are supported
99
+ # @option opts [DateTime] :pulp_created Filter results where pulp_created matches value
100
100
  # @option opts [DateTime] :pulp_created__gt Filter results where pulp_created is greater than value
101
101
  # @option opts [DateTime] :pulp_created__gte Filter results where pulp_created is greater than or equal to value
102
102
  # @option opts [DateTime] :pulp_created__lt Filter results where pulp_created is less than value
103
103
  # @option opts [DateTime] :pulp_created__lte Filter results where pulp_created is less than or equal to value
104
104
  # @option opts [Array<DateTime>] :pulp_created__range Filter results where pulp_created is between two comma separated values
105
- # @option opts [String] :fields A list of fields to include in the response.
106
- # @option opts [String] :exclude_fields A list of fields to exclude from the response.
105
+ # @option opts [Array<String>] :fields A list of fields to include in the response.
106
+ # @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
107
107
  # @return [PaginatedRepositoryVersionResponseList]
108
108
  def list(file_file_repository_href, opts = {})
109
109
  data, _status_code, _headers = list_with_http_info(file_file_repository_href, opts)
@@ -117,7 +117,7 @@ module PulpFileClient
117
117
  # @option opts [String] :content Content Unit referenced by HREF
118
118
  # @option opts [String] :content__in Content Unit referenced by HREF
119
119
  # @option opts [Integer] :limit Number of results to return per page.
120
- # @option opts [Integer] :number
120
+ # @option opts [Integer] :number Filter results where number matches value
121
121
  # @option opts [Integer] :number__gt Filter results where number is greater than value
122
122
  # @option opts [Integer] :number__gte Filter results where number is greater than or equal to value
123
123
  # @option opts [Integer] :number__lt Filter results where number is less than value
@@ -125,14 +125,14 @@ module PulpFileClient
125
125
  # @option opts [Array<Integer>] :number__range Filter results where number is between two comma separated values
126
126
  # @option opts [Integer] :offset The initial index from which to return the results.
127
127
  # @option opts [Array<String>] :ordering Ordering
128
- # @option opts [DateTime] :pulp_created ISO 8601 formatted dates are supported
128
+ # @option opts [DateTime] :pulp_created Filter results where pulp_created matches value
129
129
  # @option opts [DateTime] :pulp_created__gt Filter results where pulp_created is greater than value
130
130
  # @option opts [DateTime] :pulp_created__gte Filter results where pulp_created is greater than or equal to value
131
131
  # @option opts [DateTime] :pulp_created__lt Filter results where pulp_created is less than value
132
132
  # @option opts [DateTime] :pulp_created__lte Filter results where pulp_created is less than or equal to value
133
133
  # @option opts [Array<DateTime>] :pulp_created__range Filter results where pulp_created is between two comma separated values
134
- # @option opts [String] :fields A list of fields to include in the response.
135
- # @option opts [String] :exclude_fields A list of fields to exclude from the response.
134
+ # @option opts [Array<String>] :fields A list of fields to include in the response.
135
+ # @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
136
136
  # @return [Array<(PaginatedRepositoryVersionResponseList, Integer, Hash)>] PaginatedRepositoryVersionResponseList data, response status code and response headers
137
137
  def list_with_http_info(file_file_repository_href, opts = {})
138
138
  if @api_client.config.debugging
@@ -142,7 +142,7 @@ module PulpFileClient
142
142
  if @api_client.config.client_side_validation && file_file_repository_href.nil?
143
143
  fail ArgumentError, "Missing the required parameter 'file_file_repository_href' when calling RepositoriesFileVersionsApi.list"
144
144
  end
145
- allowable_values = ["-added_memberships", "-base_version", "-complete", "-counts", "-distribution", "-group_roles", "-number", "-pk", "-publication", "-pulp_created", "-pulp_id", "-pulp_labels", "-pulp_last_updated", "-removed_memberships", "-repository", "-user_roles", "-versions", "added_memberships", "base_version", "complete", "counts", "distribution", "group_roles", "number", "pk", "publication", "pulp_created", "pulp_id", "pulp_labels", "pulp_last_updated", "removed_memberships", "repository", "user_roles", "versions"]
145
+ allowable_values = ["-complete", "-info", "-number", "-pk", "-pulp_created", "-pulp_id", "-pulp_last_updated", "complete", "info", "number", "pk", "pulp_created", "pulp_id", "pulp_last_updated"]
146
146
  if @api_client.config.client_side_validation && opts[:'ordering'] && !opts[:'ordering'].all? { |item| allowable_values.include?(item) }
147
147
  fail ArgumentError, "invalid value for \"ordering\", must include one of #{allowable_values}"
148
148
  end
@@ -168,8 +168,8 @@ module PulpFileClient
168
168
  query_params[:'pulp_created__lt'] = opts[:'pulp_created__lt'] if !opts[:'pulp_created__lt'].nil?
169
169
  query_params[:'pulp_created__lte'] = opts[:'pulp_created__lte'] if !opts[:'pulp_created__lte'].nil?
170
170
  query_params[:'pulp_created__range'] = @api_client.build_collection_param(opts[:'pulp_created__range'], :csv) if !opts[:'pulp_created__range'].nil?
171
- query_params[:'fields'] = opts[:'fields'] if !opts[:'fields'].nil?
172
- query_params[:'exclude_fields'] = opts[:'exclude_fields'] if !opts[:'exclude_fields'].nil?
171
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :multi) if !opts[:'fields'].nil?
172
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :multi) if !opts[:'exclude_fields'].nil?
173
173
 
174
174
  # header parameters
175
175
  header_params = opts[:header_params] || {}
@@ -208,8 +208,8 @@ module PulpFileClient
208
208
  # FileRepositoryVersion represents a single file repository version.
209
209
  # @param file_file_repository_version_href [String]
210
210
  # @param [Hash] opts the optional parameters
211
- # @option opts [String] :fields A list of fields to include in the response.
212
- # @option opts [String] :exclude_fields A list of fields to exclude from the response.
211
+ # @option opts [Array<String>] :fields A list of fields to include in the response.
212
+ # @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
213
213
  # @return [RepositoryVersionResponse]
214
214
  def read(file_file_repository_version_href, opts = {})
215
215
  data, _status_code, _headers = read_with_http_info(file_file_repository_version_href, opts)
@@ -220,8 +220,8 @@ module PulpFileClient
220
220
  # FileRepositoryVersion represents a single file repository version.
221
221
  # @param file_file_repository_version_href [String]
222
222
  # @param [Hash] opts the optional parameters
223
- # @option opts [String] :fields A list of fields to include in the response.
224
- # @option opts [String] :exclude_fields A list of fields to exclude from the response.
223
+ # @option opts [Array<String>] :fields A list of fields to include in the response.
224
+ # @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
225
225
  # @return [Array<(RepositoryVersionResponse, Integer, Hash)>] RepositoryVersionResponse data, response status code and response headers
226
226
  def read_with_http_info(file_file_repository_version_href, opts = {})
227
227
  if @api_client.config.debugging
@@ -236,8 +236,8 @@ module PulpFileClient
236
236
 
237
237
  # query parameters
238
238
  query_params = opts[:query_params] || {}
239
- query_params[:'fields'] = opts[:'fields'] if !opts[:'fields'].nil?
240
- query_params[:'exclude_fields'] = opts[:'exclude_fields'] if !opts[:'exclude_fields'].nil?
239
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :multi) if !opts[:'fields'].nil?
240
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :multi) if !opts[:'exclude_fields'].nil?
241
241
 
242
242
  # header parameters
243
243
  header_params = opts[:header_params] || {}
@@ -154,7 +154,7 @@ module PulpFileClient
154
154
  case value
155
155
  when ::File, ::Tempfile
156
156
  # TODO hardcode to application/octet-stream, need better way to detect content type
157
- data[key] = Faraday::UploadIO.new(value.path, 'application/octet-stream', value.path)
157
+ data[key] = Faraday::FilePart.new(value.path, 'application/octet-stream', value.path)
158
158
  when ::Array, nil
159
159
  # let Faraday handle Array and nil parameters
160
160
  data[key] = value
@@ -49,7 +49,7 @@ module PulpFileClient
49
49
  {
50
50
  :'base_path' => :'String',
51
51
  :'content_guard' => :'String',
52
- :'pulp_labels' => :'Object',
52
+ :'pulp_labels' => :'Hash<String, String>',
53
53
  :'name' => :'String',
54
54
  :'repository' => :'String',
55
55
  :'publication' => :'String'
@@ -89,7 +89,9 @@ module PulpFileClient
89
89
  end
90
90
 
91
91
  if attributes.key?(:'pulp_labels')
92
- self.pulp_labels = attributes[:'pulp_labels']
92
+ if (value = attributes[:'pulp_labels']).is_a?(Hash)
93
+ self.pulp_labels = value
94
+ end
93
95
  end
94
96
 
95
97
  if attributes.key?(:'name')
@@ -63,7 +63,7 @@ module PulpFileClient
63
63
  :'base_path' => :'String',
64
64
  :'base_url' => :'String',
65
65
  :'content_guard' => :'String',
66
- :'pulp_labels' => :'Object',
66
+ :'pulp_labels' => :'Hash<String, String>',
67
67
  :'name' => :'String',
68
68
  :'repository' => :'String',
69
69
  :'publication' => :'String'
@@ -115,7 +115,9 @@ module PulpFileClient
115
115
  end
116
116
 
117
117
  if attributes.key?(:'pulp_labels')
118
- self.pulp_labels = attributes[:'pulp_labels']
118
+ if (value = attributes[:'pulp_labels']).is_a?(Hash)
119
+ self.pulp_labels = value
120
+ end
119
121
  end
120
122
 
121
123
  if attributes.key?(:'name')
@@ -118,7 +118,7 @@ module PulpFileClient
118
118
  :'proxy_password' => :'String',
119
119
  :'username' => :'String',
120
120
  :'password' => :'String',
121
- :'pulp_labels' => :'Object',
121
+ :'pulp_labels' => :'Hash<String, String>',
122
122
  :'download_concurrency' => :'Integer',
123
123
  :'max_retries' => :'Integer',
124
124
  :'policy' => :'PolicyEnum',
@@ -212,7 +212,9 @@ module PulpFileClient
212
212
  end
213
213
 
214
214
  if attributes.key?(:'pulp_labels')
215
- self.pulp_labels = attributes[:'pulp_labels']
215
+ if (value = attributes[:'pulp_labels']).is_a?(Hash)
216
+ self.pulp_labels = value
217
+ end
216
218
  end
217
219
 
218
220
  if attributes.key?(:'download_concurrency')
@@ -70,6 +70,9 @@ module PulpFileClient
70
70
  # Limits requests per second for each concurrent downloader
71
71
  attr_accessor :rate_limit
72
72
 
73
+ # List of hidden (write only) fields
74
+ attr_accessor :hidden_fields
75
+
73
76
  # Attribute mapping from ruby-style variable name to JSON key.
74
77
  def self.attribute_map
75
78
  {
@@ -91,7 +94,8 @@ module PulpFileClient
91
94
  :'sock_connect_timeout' => :'sock_connect_timeout',
92
95
  :'sock_read_timeout' => :'sock_read_timeout',
93
96
  :'headers' => :'headers',
94
- :'rate_limit' => :'rate_limit'
97
+ :'rate_limit' => :'rate_limit',
98
+ :'hidden_fields' => :'hidden_fields'
95
99
  }
96
100
  end
97
101
 
@@ -106,7 +110,7 @@ module PulpFileClient
106
110
  :'client_cert' => :'String',
107
111
  :'tls_validation' => :'Boolean',
108
112
  :'proxy_url' => :'String',
109
- :'pulp_labels' => :'Object',
113
+ :'pulp_labels' => :'Hash<String, String>',
110
114
  :'pulp_last_updated' => :'DateTime',
111
115
  :'download_concurrency' => :'Integer',
112
116
  :'max_retries' => :'Integer',
@@ -116,7 +120,8 @@ module PulpFileClient
116
120
  :'sock_connect_timeout' => :'Float',
117
121
  :'sock_read_timeout' => :'Float',
118
122
  :'headers' => :'Array<Object>',
119
- :'rate_limit' => :'Integer'
123
+ :'rate_limit' => :'Integer',
124
+ :'hidden_fields' => :'Array<FileFileRemoteResponseHiddenFields>'
120
125
  }
121
126
  end
122
127
 
@@ -132,7 +137,7 @@ module PulpFileClient
132
137
  :'connect_timeout',
133
138
  :'sock_connect_timeout',
134
139
  :'sock_read_timeout',
135
- :'rate_limit'
140
+ :'rate_limit',
136
141
  ])
137
142
  end
138
143
 
@@ -184,7 +189,9 @@ module PulpFileClient
184
189
  end
185
190
 
186
191
  if attributes.key?(:'pulp_labels')
187
- self.pulp_labels = attributes[:'pulp_labels']
192
+ if (value = attributes[:'pulp_labels']).is_a?(Hash)
193
+ self.pulp_labels = value
194
+ end
188
195
  end
189
196
 
190
197
  if attributes.key?(:'pulp_last_updated')
@@ -228,6 +235,12 @@ module PulpFileClient
228
235
  if attributes.key?(:'rate_limit')
229
236
  self.rate_limit = attributes[:'rate_limit']
230
237
  end
238
+
239
+ if attributes.key?(:'hidden_fields')
240
+ if (value = attributes[:'hidden_fields']).is_a?(Array)
241
+ self.hidden_fields = value
242
+ end
243
+ end
231
244
  end
232
245
 
233
246
  # Show invalid properties with the reasons. Usually used together with valid?
@@ -351,7 +364,8 @@ module PulpFileClient
351
364
  sock_connect_timeout == o.sock_connect_timeout &&
352
365
  sock_read_timeout == o.sock_read_timeout &&
353
366
  headers == o.headers &&
354
- rate_limit == o.rate_limit
367
+ rate_limit == o.rate_limit &&
368
+ hidden_fields == o.hidden_fields
355
369
  end
356
370
 
357
371
  # @see the `==` method
@@ -363,7 +377,7 @@ module PulpFileClient
363
377
  # Calculates hash code according to all attributes.
364
378
  # @return [Integer] Hash code
365
379
  def hash
366
- [pulp_href, pulp_created, name, url, ca_cert, client_cert, tls_validation, proxy_url, pulp_labels, pulp_last_updated, download_concurrency, max_retries, policy, total_timeout, connect_timeout, sock_connect_timeout, sock_read_timeout, headers, rate_limit].hash
380
+ [pulp_href, pulp_created, name, url, ca_cert, client_cert, tls_validation, proxy_url, pulp_labels, pulp_last_updated, download_concurrency, max_retries, policy, total_timeout, connect_timeout, sock_connect_timeout, sock_read_timeout, headers, rate_limit, hidden_fields].hash
367
381
  end
368
382
 
369
383
  # Builds the object from hash
@@ -0,0 +1,215 @@
1
+ =begin
2
+ #Pulp 3 API
3
+
4
+ #Fetch, Upload, Organize, and Distribute Software Packages
5
+
6
+ The version of the OpenAPI document: v3
7
+ Contact: pulp-list@redhat.com
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 4.3.1
10
+
11
+ =end
12
+
13
+ require 'date'
14
+
15
+ module PulpFileClient
16
+ class FileFileRemoteResponseHiddenFields
17
+ attr_accessor :name
18
+
19
+ attr_accessor :is_set
20
+
21
+ # Attribute mapping from ruby-style variable name to JSON key.
22
+ def self.attribute_map
23
+ {
24
+ :'name' => :'name',
25
+ :'is_set' => :'is_set'
26
+ }
27
+ end
28
+
29
+ # Attribute type mapping.
30
+ def self.openapi_types
31
+ {
32
+ :'name' => :'String',
33
+ :'is_set' => :'Boolean'
34
+ }
35
+ end
36
+
37
+ # List of attributes with nullable: true
38
+ def self.openapi_nullable
39
+ Set.new([
40
+ ])
41
+ end
42
+
43
+ # Initializes the object
44
+ # @param [Hash] attributes Model attributes in the form of hash
45
+ def initialize(attributes = {})
46
+ if (!attributes.is_a?(Hash))
47
+ fail ArgumentError, "The input argument (attributes) must be a hash in `PulpFileClient::FileFileRemoteResponseHiddenFields` initialize method"
48
+ end
49
+
50
+ # check to see if the attribute exists and convert string to symbol for hash key
51
+ attributes = attributes.each_with_object({}) { |(k, v), h|
52
+ if (!self.class.attribute_map.key?(k.to_sym))
53
+ fail ArgumentError, "`#{k}` is not a valid attribute in `PulpFileClient::FileFileRemoteResponseHiddenFields`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
54
+ end
55
+ h[k.to_sym] = v
56
+ }
57
+
58
+ if attributes.key?(:'name')
59
+ self.name = attributes[:'name']
60
+ end
61
+
62
+ if attributes.key?(:'is_set')
63
+ self.is_set = attributes[:'is_set']
64
+ end
65
+ end
66
+
67
+ # Show invalid properties with the reasons. Usually used together with valid?
68
+ # @return Array for valid properties with the reasons
69
+ def list_invalid_properties
70
+ invalid_properties = Array.new
71
+ invalid_properties
72
+ end
73
+
74
+ # Check to see if the all the properties in the model are valid
75
+ # @return true if the model is valid
76
+ def valid?
77
+ true
78
+ end
79
+
80
+ # Checks equality by comparing each attribute.
81
+ # @param [Object] Object to be compared
82
+ def ==(o)
83
+ return true if self.equal?(o)
84
+ self.class == o.class &&
85
+ name == o.name &&
86
+ is_set == o.is_set
87
+ end
88
+
89
+ # @see the `==` method
90
+ # @param [Object] Object to be compared
91
+ def eql?(o)
92
+ self == o
93
+ end
94
+
95
+ # Calculates hash code according to all attributes.
96
+ # @return [Integer] Hash code
97
+ def hash
98
+ [name, is_set].hash
99
+ end
100
+
101
+ # Builds the object from hash
102
+ # @param [Hash] attributes Model attributes in the form of hash
103
+ # @return [Object] Returns the model itself
104
+ def self.build_from_hash(attributes)
105
+ new.build_from_hash(attributes)
106
+ end
107
+
108
+ # Builds the object from hash
109
+ # @param [Hash] attributes Model attributes in the form of hash
110
+ # @return [Object] Returns the model itself
111
+ def build_from_hash(attributes)
112
+ return nil unless attributes.is_a?(Hash)
113
+ self.class.openapi_types.each_pair do |key, type|
114
+ if type =~ /\AArray<(.*)>/i
115
+ # check to ensure the input is an array given that the attribute
116
+ # is documented as an array but the input is not
117
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
118
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
119
+ end
120
+ elsif !attributes[self.class.attribute_map[key]].nil?
121
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
122
+ end # or else data not found in attributes(hash), not an issue as the data can be optional
123
+ end
124
+
125
+ self
126
+ end
127
+
128
+ # Deserializes the data based on type
129
+ # @param string type Data type
130
+ # @param string value Value to be deserialized
131
+ # @return [Object] Deserialized data
132
+ def _deserialize(type, value)
133
+ case type.to_sym
134
+ when :DateTime
135
+ DateTime.parse(value)
136
+ when :Date
137
+ Date.parse(value)
138
+ when :String
139
+ value.to_s
140
+ when :Integer
141
+ value.to_i
142
+ when :Float
143
+ value.to_f
144
+ when :Boolean
145
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
146
+ true
147
+ else
148
+ false
149
+ end
150
+ when :Object
151
+ # generic object (usually a Hash), return directly
152
+ value
153
+ when /\AArray<(?<inner_type>.+)>\z/
154
+ inner_type = Regexp.last_match[:inner_type]
155
+ value.map { |v| _deserialize(inner_type, v) }
156
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
157
+ k_type = Regexp.last_match[:k_type]
158
+ v_type = Regexp.last_match[:v_type]
159
+ {}.tap do |hash|
160
+ value.each do |k, v|
161
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
162
+ end
163
+ end
164
+ else # model
165
+ PulpFileClient.const_get(type).build_from_hash(value)
166
+ end
167
+ end
168
+
169
+ # Returns the string representation of the object
170
+ # @return [String] String presentation of the object
171
+ def to_s
172
+ to_hash.to_s
173
+ end
174
+
175
+ # to_body is an alias to to_hash (backward compatibility)
176
+ # @return [Hash] Returns the object in the form of hash
177
+ def to_body
178
+ to_hash
179
+ end
180
+
181
+ # Returns the object in the form of hash
182
+ # @return [Hash] Returns the object in the form of hash
183
+ def to_hash
184
+ hash = {}
185
+ self.class.attribute_map.each_pair do |attr, param|
186
+ value = self.send(attr)
187
+ if value.nil?
188
+ is_nullable = self.class.openapi_nullable.include?(attr)
189
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
190
+ end
191
+
192
+ hash[param] = _to_hash(value)
193
+ end
194
+ hash
195
+ end
196
+
197
+ # Outputs non-array value in the form of hash
198
+ # For object, use to_hash. Otherwise, just return the value
199
+ # @param [Object] value Any valid value
200
+ # @return [Hash] Returns the value in the form of hash
201
+ def _to_hash(value)
202
+ if value.is_a?(Array)
203
+ value.compact.map { |v| _to_hash(v) }
204
+ elsif value.is_a?(Hash)
205
+ {}.tap do |hash|
206
+ value.each { |k, v| hash[k] = _to_hash(v) }
207
+ end
208
+ elsif value.respond_to? :to_hash
209
+ value.to_hash
210
+ else
211
+ value
212
+ end
213
+ end
214
+ end
215
+ end