pulp_maven_client 0.24.1 → 0.25.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +26 -4
- data/docs/ContentPackageApi.md +351 -0
- data/docs/DistributionsMavenApi.md +312 -0
- data/docs/MavenMavenPackageResponse.md +48 -0
- data/docs/MyPermissionsResponse.md +18 -0
- data/docs/NestedRole.md +22 -0
- data/docs/NestedRoleResponse.md +22 -0
- data/docs/ObjectRolesResponse.md +18 -0
- data/docs/PaginatedmavenMavenPackageResponseList.md +24 -0
- data/docs/RemotesMavenApi.md +312 -0
- data/docs/RepositoriesMavenApi.md +315 -3
- data/lib/pulp_maven_client/api/content_package_api.rb +369 -0
- data/lib/pulp_maven_client/api/distributions_maven_api.rb +298 -0
- data/lib/pulp_maven_client/api/remotes_maven_api.rb +298 -0
- data/lib/pulp_maven_client/api/repositories_maven_api.rb +304 -6
- data/lib/pulp_maven_client/models/maven_maven_package_response.rb +371 -0
- data/lib/pulp_maven_client/models/my_permissions_response.rb +223 -0
- data/lib/pulp_maven_client/models/nested_role.rb +263 -0
- data/lib/pulp_maven_client/models/nested_role_response.rb +244 -0
- data/lib/pulp_maven_client/models/object_roles_response.rb +223 -0
- data/lib/pulp_maven_client/models/paginatedmaven_maven_package_response_list.rb +257 -0
- data/lib/pulp_maven_client/version.rb +1 -1
- data/lib/pulp_maven_client.rb +7 -0
- data/spec/api/content_package_api_spec.rb +109 -0
- data/spec/api/distributions_maven_api_spec.rb +58 -0
- data/spec/api/remotes_maven_api_spec.rb +58 -0
- data/spec/api/repositories_maven_api_spec.rb +61 -3
- data/spec/models/maven_maven_package_response_spec.rb +126 -0
- data/spec/models/my_permissions_response_spec.rb +36 -0
- data/spec/models/nested_role_response_spec.rb +48 -0
- data/spec/models/nested_role_spec.rb +48 -0
- data/spec/models/object_roles_response_spec.rb +36 -0
- data/spec/models/paginatedmaven_maven_package_response_list_spec.rb +54 -0
- metadata +56 -28
|
@@ -19,6 +19,83 @@ module PulpMavenClient
|
|
|
19
19
|
def initialize(api_client = ApiClient.default)
|
|
20
20
|
@api_client = api_client
|
|
21
21
|
end
|
|
22
|
+
# Add a role
|
|
23
|
+
# Add a role for this object to users/groups.
|
|
24
|
+
# @param maven_maven_distribution_href [String]
|
|
25
|
+
# @param nested_role [NestedRole]
|
|
26
|
+
# @param [Hash] opts the optional parameters
|
|
27
|
+
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
28
|
+
# @return [NestedRoleResponse]
|
|
29
|
+
def add_role(maven_maven_distribution_href, nested_role, opts = {})
|
|
30
|
+
data, _status_code, _headers = add_role_with_http_info(maven_maven_distribution_href, nested_role, opts)
|
|
31
|
+
data
|
|
32
|
+
end
|
|
33
|
+
|
|
34
|
+
# Add a role
|
|
35
|
+
# Add a role for this object to users/groups.
|
|
36
|
+
# @param maven_maven_distribution_href [String]
|
|
37
|
+
# @param nested_role [NestedRole]
|
|
38
|
+
# @param [Hash] opts the optional parameters
|
|
39
|
+
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
40
|
+
# @return [Array<(NestedRoleResponse, Integer, Hash)>] NestedRoleResponse data, response status code and response headers
|
|
41
|
+
def add_role_with_http_info(maven_maven_distribution_href, nested_role, opts = {})
|
|
42
|
+
if @api_client.config.debugging
|
|
43
|
+
@api_client.config.logger.debug 'Calling API: DistributionsMavenApi.add_role ...'
|
|
44
|
+
end
|
|
45
|
+
# verify the required parameter 'maven_maven_distribution_href' is set
|
|
46
|
+
if @api_client.config.client_side_validation && maven_maven_distribution_href.nil?
|
|
47
|
+
fail ArgumentError, "Missing the required parameter 'maven_maven_distribution_href' when calling DistributionsMavenApi.add_role"
|
|
48
|
+
end
|
|
49
|
+
# verify the required parameter 'nested_role' is set
|
|
50
|
+
if @api_client.config.client_side_validation && nested_role.nil?
|
|
51
|
+
fail ArgumentError, "Missing the required parameter 'nested_role' when calling DistributionsMavenApi.add_role"
|
|
52
|
+
end
|
|
53
|
+
# resource path
|
|
54
|
+
local_var_path = '{maven_maven_distribution_href}add_role/'.sub('{' + 'maven_maven_distribution_href' + '}', CGI.escape(maven_maven_distribution_href.to_s).gsub('%2F', '/'))
|
|
55
|
+
|
|
56
|
+
# query parameters
|
|
57
|
+
query_params = opts[:query_params] || {}
|
|
58
|
+
|
|
59
|
+
# header parameters
|
|
60
|
+
header_params = opts[:header_params] || {}
|
|
61
|
+
# HTTP header 'Accept' (if needed)
|
|
62
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
63
|
+
# HTTP header 'Content-Type'
|
|
64
|
+
content_type = @api_client.select_header_content_type(['application/json', 'application/x-www-form-urlencoded', 'multipart/form-data'])
|
|
65
|
+
if !content_type.nil?
|
|
66
|
+
header_params['Content-Type'] = content_type
|
|
67
|
+
end
|
|
68
|
+
header_params[:'X-Task-Diagnostics'] = @api_client.build_collection_param(opts[:'x_task_diagnostics'], :csv) if !opts[:'x_task_diagnostics'].nil?
|
|
69
|
+
|
|
70
|
+
# form parameters
|
|
71
|
+
form_params = opts[:form_params] || {}
|
|
72
|
+
|
|
73
|
+
# http body (model)
|
|
74
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(nested_role)
|
|
75
|
+
|
|
76
|
+
# return_type
|
|
77
|
+
return_type = opts[:debug_return_type] || 'NestedRoleResponse'
|
|
78
|
+
|
|
79
|
+
# auth_names
|
|
80
|
+
auth_names = opts[:debug_auth_names] || ['basicAuth']
|
|
81
|
+
|
|
82
|
+
new_options = opts.merge(
|
|
83
|
+
:operation => :"DistributionsMavenApi.add_role",
|
|
84
|
+
:header_params => header_params,
|
|
85
|
+
:query_params => query_params,
|
|
86
|
+
:form_params => form_params,
|
|
87
|
+
:body => post_body,
|
|
88
|
+
:auth_names => auth_names,
|
|
89
|
+
:return_type => return_type
|
|
90
|
+
)
|
|
91
|
+
|
|
92
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
93
|
+
if @api_client.config.debugging
|
|
94
|
+
@api_client.config.logger.debug "API called: DistributionsMavenApi#add_role\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
95
|
+
end
|
|
96
|
+
return data, status_code, headers
|
|
97
|
+
end
|
|
98
|
+
|
|
22
99
|
# Create a maven distribution
|
|
23
100
|
# Trigger an asynchronous create task
|
|
24
101
|
# @param maven_maven_distribution [MavenMavenDistribution]
|
|
@@ -301,6 +378,150 @@ module PulpMavenClient
|
|
|
301
378
|
return data, status_code, headers
|
|
302
379
|
end
|
|
303
380
|
|
|
381
|
+
# List roles
|
|
382
|
+
# List roles assigned to this object.
|
|
383
|
+
# @param maven_maven_distribution_href [String]
|
|
384
|
+
# @param [Hash] opts the optional parameters
|
|
385
|
+
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
386
|
+
# @option opts [Array<String>] :fields A list of fields to include in the response.
|
|
387
|
+
# @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
|
|
388
|
+
# @return [ObjectRolesResponse]
|
|
389
|
+
def list_roles(maven_maven_distribution_href, opts = {})
|
|
390
|
+
data, _status_code, _headers = list_roles_with_http_info(maven_maven_distribution_href, opts)
|
|
391
|
+
data
|
|
392
|
+
end
|
|
393
|
+
|
|
394
|
+
# List roles
|
|
395
|
+
# List roles assigned to this object.
|
|
396
|
+
# @param maven_maven_distribution_href [String]
|
|
397
|
+
# @param [Hash] opts the optional parameters
|
|
398
|
+
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
399
|
+
# @option opts [Array<String>] :fields A list of fields to include in the response.
|
|
400
|
+
# @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
|
|
401
|
+
# @return [Array<(ObjectRolesResponse, Integer, Hash)>] ObjectRolesResponse data, response status code and response headers
|
|
402
|
+
def list_roles_with_http_info(maven_maven_distribution_href, opts = {})
|
|
403
|
+
if @api_client.config.debugging
|
|
404
|
+
@api_client.config.logger.debug 'Calling API: DistributionsMavenApi.list_roles ...'
|
|
405
|
+
end
|
|
406
|
+
# verify the required parameter 'maven_maven_distribution_href' is set
|
|
407
|
+
if @api_client.config.client_side_validation && maven_maven_distribution_href.nil?
|
|
408
|
+
fail ArgumentError, "Missing the required parameter 'maven_maven_distribution_href' when calling DistributionsMavenApi.list_roles"
|
|
409
|
+
end
|
|
410
|
+
# resource path
|
|
411
|
+
local_var_path = '{maven_maven_distribution_href}list_roles/'.sub('{' + 'maven_maven_distribution_href' + '}', CGI.escape(maven_maven_distribution_href.to_s).gsub('%2F', '/'))
|
|
412
|
+
|
|
413
|
+
# query parameters
|
|
414
|
+
query_params = opts[:query_params] || {}
|
|
415
|
+
query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :multi) if !opts[:'fields'].nil?
|
|
416
|
+
query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :multi) if !opts[:'exclude_fields'].nil?
|
|
417
|
+
|
|
418
|
+
# header parameters
|
|
419
|
+
header_params = opts[:header_params] || {}
|
|
420
|
+
# HTTP header 'Accept' (if needed)
|
|
421
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
422
|
+
header_params[:'X-Task-Diagnostics'] = @api_client.build_collection_param(opts[:'x_task_diagnostics'], :csv) if !opts[:'x_task_diagnostics'].nil?
|
|
423
|
+
|
|
424
|
+
# form parameters
|
|
425
|
+
form_params = opts[:form_params] || {}
|
|
426
|
+
|
|
427
|
+
# http body (model)
|
|
428
|
+
post_body = opts[:debug_body]
|
|
429
|
+
|
|
430
|
+
# return_type
|
|
431
|
+
return_type = opts[:debug_return_type] || 'ObjectRolesResponse'
|
|
432
|
+
|
|
433
|
+
# auth_names
|
|
434
|
+
auth_names = opts[:debug_auth_names] || ['basicAuth']
|
|
435
|
+
|
|
436
|
+
new_options = opts.merge(
|
|
437
|
+
:operation => :"DistributionsMavenApi.list_roles",
|
|
438
|
+
:header_params => header_params,
|
|
439
|
+
:query_params => query_params,
|
|
440
|
+
:form_params => form_params,
|
|
441
|
+
:body => post_body,
|
|
442
|
+
:auth_names => auth_names,
|
|
443
|
+
:return_type => return_type
|
|
444
|
+
)
|
|
445
|
+
|
|
446
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
447
|
+
if @api_client.config.debugging
|
|
448
|
+
@api_client.config.logger.debug "API called: DistributionsMavenApi#list_roles\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
449
|
+
end
|
|
450
|
+
return data, status_code, headers
|
|
451
|
+
end
|
|
452
|
+
|
|
453
|
+
# List user permissions
|
|
454
|
+
# List permissions available to the current user on this object.
|
|
455
|
+
# @param maven_maven_distribution_href [String]
|
|
456
|
+
# @param [Hash] opts the optional parameters
|
|
457
|
+
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
458
|
+
# @option opts [Array<String>] :fields A list of fields to include in the response.
|
|
459
|
+
# @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
|
|
460
|
+
# @return [MyPermissionsResponse]
|
|
461
|
+
def my_permissions(maven_maven_distribution_href, opts = {})
|
|
462
|
+
data, _status_code, _headers = my_permissions_with_http_info(maven_maven_distribution_href, opts)
|
|
463
|
+
data
|
|
464
|
+
end
|
|
465
|
+
|
|
466
|
+
# List user permissions
|
|
467
|
+
# List permissions available to the current user on this object.
|
|
468
|
+
# @param maven_maven_distribution_href [String]
|
|
469
|
+
# @param [Hash] opts the optional parameters
|
|
470
|
+
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
471
|
+
# @option opts [Array<String>] :fields A list of fields to include in the response.
|
|
472
|
+
# @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
|
|
473
|
+
# @return [Array<(MyPermissionsResponse, Integer, Hash)>] MyPermissionsResponse data, response status code and response headers
|
|
474
|
+
def my_permissions_with_http_info(maven_maven_distribution_href, opts = {})
|
|
475
|
+
if @api_client.config.debugging
|
|
476
|
+
@api_client.config.logger.debug 'Calling API: DistributionsMavenApi.my_permissions ...'
|
|
477
|
+
end
|
|
478
|
+
# verify the required parameter 'maven_maven_distribution_href' is set
|
|
479
|
+
if @api_client.config.client_side_validation && maven_maven_distribution_href.nil?
|
|
480
|
+
fail ArgumentError, "Missing the required parameter 'maven_maven_distribution_href' when calling DistributionsMavenApi.my_permissions"
|
|
481
|
+
end
|
|
482
|
+
# resource path
|
|
483
|
+
local_var_path = '{maven_maven_distribution_href}my_permissions/'.sub('{' + 'maven_maven_distribution_href' + '}', CGI.escape(maven_maven_distribution_href.to_s).gsub('%2F', '/'))
|
|
484
|
+
|
|
485
|
+
# query parameters
|
|
486
|
+
query_params = opts[:query_params] || {}
|
|
487
|
+
query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :multi) if !opts[:'fields'].nil?
|
|
488
|
+
query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :multi) if !opts[:'exclude_fields'].nil?
|
|
489
|
+
|
|
490
|
+
# header parameters
|
|
491
|
+
header_params = opts[:header_params] || {}
|
|
492
|
+
# HTTP header 'Accept' (if needed)
|
|
493
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
494
|
+
header_params[:'X-Task-Diagnostics'] = @api_client.build_collection_param(opts[:'x_task_diagnostics'], :csv) if !opts[:'x_task_diagnostics'].nil?
|
|
495
|
+
|
|
496
|
+
# form parameters
|
|
497
|
+
form_params = opts[:form_params] || {}
|
|
498
|
+
|
|
499
|
+
# http body (model)
|
|
500
|
+
post_body = opts[:debug_body]
|
|
501
|
+
|
|
502
|
+
# return_type
|
|
503
|
+
return_type = opts[:debug_return_type] || 'MyPermissionsResponse'
|
|
504
|
+
|
|
505
|
+
# auth_names
|
|
506
|
+
auth_names = opts[:debug_auth_names] || ['basicAuth']
|
|
507
|
+
|
|
508
|
+
new_options = opts.merge(
|
|
509
|
+
:operation => :"DistributionsMavenApi.my_permissions",
|
|
510
|
+
:header_params => header_params,
|
|
511
|
+
:query_params => query_params,
|
|
512
|
+
:form_params => form_params,
|
|
513
|
+
:body => post_body,
|
|
514
|
+
:auth_names => auth_names,
|
|
515
|
+
:return_type => return_type
|
|
516
|
+
)
|
|
517
|
+
|
|
518
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
519
|
+
if @api_client.config.debugging
|
|
520
|
+
@api_client.config.logger.debug "API called: DistributionsMavenApi#my_permissions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
521
|
+
end
|
|
522
|
+
return data, status_code, headers
|
|
523
|
+
end
|
|
524
|
+
|
|
304
525
|
# Update a maven distribution
|
|
305
526
|
# Update the entity partially and trigger an asynchronous task if necessary
|
|
306
527
|
# @param maven_maven_distribution_href [String]
|
|
@@ -450,6 +671,83 @@ module PulpMavenClient
|
|
|
450
671
|
return data, status_code, headers
|
|
451
672
|
end
|
|
452
673
|
|
|
674
|
+
# Remove a role
|
|
675
|
+
# Remove a role for this object from users/groups.
|
|
676
|
+
# @param maven_maven_distribution_href [String]
|
|
677
|
+
# @param nested_role [NestedRole]
|
|
678
|
+
# @param [Hash] opts the optional parameters
|
|
679
|
+
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
680
|
+
# @return [NestedRoleResponse]
|
|
681
|
+
def remove_role(maven_maven_distribution_href, nested_role, opts = {})
|
|
682
|
+
data, _status_code, _headers = remove_role_with_http_info(maven_maven_distribution_href, nested_role, opts)
|
|
683
|
+
data
|
|
684
|
+
end
|
|
685
|
+
|
|
686
|
+
# Remove a role
|
|
687
|
+
# Remove a role for this object from users/groups.
|
|
688
|
+
# @param maven_maven_distribution_href [String]
|
|
689
|
+
# @param nested_role [NestedRole]
|
|
690
|
+
# @param [Hash] opts the optional parameters
|
|
691
|
+
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
692
|
+
# @return [Array<(NestedRoleResponse, Integer, Hash)>] NestedRoleResponse data, response status code and response headers
|
|
693
|
+
def remove_role_with_http_info(maven_maven_distribution_href, nested_role, opts = {})
|
|
694
|
+
if @api_client.config.debugging
|
|
695
|
+
@api_client.config.logger.debug 'Calling API: DistributionsMavenApi.remove_role ...'
|
|
696
|
+
end
|
|
697
|
+
# verify the required parameter 'maven_maven_distribution_href' is set
|
|
698
|
+
if @api_client.config.client_side_validation && maven_maven_distribution_href.nil?
|
|
699
|
+
fail ArgumentError, "Missing the required parameter 'maven_maven_distribution_href' when calling DistributionsMavenApi.remove_role"
|
|
700
|
+
end
|
|
701
|
+
# verify the required parameter 'nested_role' is set
|
|
702
|
+
if @api_client.config.client_side_validation && nested_role.nil?
|
|
703
|
+
fail ArgumentError, "Missing the required parameter 'nested_role' when calling DistributionsMavenApi.remove_role"
|
|
704
|
+
end
|
|
705
|
+
# resource path
|
|
706
|
+
local_var_path = '{maven_maven_distribution_href}remove_role/'.sub('{' + 'maven_maven_distribution_href' + '}', CGI.escape(maven_maven_distribution_href.to_s).gsub('%2F', '/'))
|
|
707
|
+
|
|
708
|
+
# query parameters
|
|
709
|
+
query_params = opts[:query_params] || {}
|
|
710
|
+
|
|
711
|
+
# header parameters
|
|
712
|
+
header_params = opts[:header_params] || {}
|
|
713
|
+
# HTTP header 'Accept' (if needed)
|
|
714
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
715
|
+
# HTTP header 'Content-Type'
|
|
716
|
+
content_type = @api_client.select_header_content_type(['application/json', 'application/x-www-form-urlencoded', 'multipart/form-data'])
|
|
717
|
+
if !content_type.nil?
|
|
718
|
+
header_params['Content-Type'] = content_type
|
|
719
|
+
end
|
|
720
|
+
header_params[:'X-Task-Diagnostics'] = @api_client.build_collection_param(opts[:'x_task_diagnostics'], :csv) if !opts[:'x_task_diagnostics'].nil?
|
|
721
|
+
|
|
722
|
+
# form parameters
|
|
723
|
+
form_params = opts[:form_params] || {}
|
|
724
|
+
|
|
725
|
+
# http body (model)
|
|
726
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(nested_role)
|
|
727
|
+
|
|
728
|
+
# return_type
|
|
729
|
+
return_type = opts[:debug_return_type] || 'NestedRoleResponse'
|
|
730
|
+
|
|
731
|
+
# auth_names
|
|
732
|
+
auth_names = opts[:debug_auth_names] || ['basicAuth']
|
|
733
|
+
|
|
734
|
+
new_options = opts.merge(
|
|
735
|
+
:operation => :"DistributionsMavenApi.remove_role",
|
|
736
|
+
:header_params => header_params,
|
|
737
|
+
:query_params => query_params,
|
|
738
|
+
:form_params => form_params,
|
|
739
|
+
:body => post_body,
|
|
740
|
+
:auth_names => auth_names,
|
|
741
|
+
:return_type => return_type
|
|
742
|
+
)
|
|
743
|
+
|
|
744
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
745
|
+
if @api_client.config.debugging
|
|
746
|
+
@api_client.config.logger.debug "API called: DistributionsMavenApi#remove_role\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
747
|
+
end
|
|
748
|
+
return data, status_code, headers
|
|
749
|
+
end
|
|
750
|
+
|
|
453
751
|
# Set a label
|
|
454
752
|
# Set a single pulp_label on the object to a specific value or null.
|
|
455
753
|
# @param maven_maven_distribution_href [String]
|
|
@@ -19,6 +19,83 @@ module PulpMavenClient
|
|
|
19
19
|
def initialize(api_client = ApiClient.default)
|
|
20
20
|
@api_client = api_client
|
|
21
21
|
end
|
|
22
|
+
# Add a role
|
|
23
|
+
# Add a role for this object to users/groups.
|
|
24
|
+
# @param maven_maven_remote_href [String]
|
|
25
|
+
# @param nested_role [NestedRole]
|
|
26
|
+
# @param [Hash] opts the optional parameters
|
|
27
|
+
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
28
|
+
# @return [NestedRoleResponse]
|
|
29
|
+
def add_role(maven_maven_remote_href, nested_role, opts = {})
|
|
30
|
+
data, _status_code, _headers = add_role_with_http_info(maven_maven_remote_href, nested_role, opts)
|
|
31
|
+
data
|
|
32
|
+
end
|
|
33
|
+
|
|
34
|
+
# Add a role
|
|
35
|
+
# Add a role for this object to users/groups.
|
|
36
|
+
# @param maven_maven_remote_href [String]
|
|
37
|
+
# @param nested_role [NestedRole]
|
|
38
|
+
# @param [Hash] opts the optional parameters
|
|
39
|
+
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
40
|
+
# @return [Array<(NestedRoleResponse, Integer, Hash)>] NestedRoleResponse data, response status code and response headers
|
|
41
|
+
def add_role_with_http_info(maven_maven_remote_href, nested_role, opts = {})
|
|
42
|
+
if @api_client.config.debugging
|
|
43
|
+
@api_client.config.logger.debug 'Calling API: RemotesMavenApi.add_role ...'
|
|
44
|
+
end
|
|
45
|
+
# verify the required parameter 'maven_maven_remote_href' is set
|
|
46
|
+
if @api_client.config.client_side_validation && maven_maven_remote_href.nil?
|
|
47
|
+
fail ArgumentError, "Missing the required parameter 'maven_maven_remote_href' when calling RemotesMavenApi.add_role"
|
|
48
|
+
end
|
|
49
|
+
# verify the required parameter 'nested_role' is set
|
|
50
|
+
if @api_client.config.client_side_validation && nested_role.nil?
|
|
51
|
+
fail ArgumentError, "Missing the required parameter 'nested_role' when calling RemotesMavenApi.add_role"
|
|
52
|
+
end
|
|
53
|
+
# resource path
|
|
54
|
+
local_var_path = '{maven_maven_remote_href}add_role/'.sub('{' + 'maven_maven_remote_href' + '}', CGI.escape(maven_maven_remote_href.to_s).gsub('%2F', '/'))
|
|
55
|
+
|
|
56
|
+
# query parameters
|
|
57
|
+
query_params = opts[:query_params] || {}
|
|
58
|
+
|
|
59
|
+
# header parameters
|
|
60
|
+
header_params = opts[:header_params] || {}
|
|
61
|
+
# HTTP header 'Accept' (if needed)
|
|
62
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
63
|
+
# HTTP header 'Content-Type'
|
|
64
|
+
content_type = @api_client.select_header_content_type(['application/json', 'application/x-www-form-urlencoded', 'multipart/form-data'])
|
|
65
|
+
if !content_type.nil?
|
|
66
|
+
header_params['Content-Type'] = content_type
|
|
67
|
+
end
|
|
68
|
+
header_params[:'X-Task-Diagnostics'] = @api_client.build_collection_param(opts[:'x_task_diagnostics'], :csv) if !opts[:'x_task_diagnostics'].nil?
|
|
69
|
+
|
|
70
|
+
# form parameters
|
|
71
|
+
form_params = opts[:form_params] || {}
|
|
72
|
+
|
|
73
|
+
# http body (model)
|
|
74
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(nested_role)
|
|
75
|
+
|
|
76
|
+
# return_type
|
|
77
|
+
return_type = opts[:debug_return_type] || 'NestedRoleResponse'
|
|
78
|
+
|
|
79
|
+
# auth_names
|
|
80
|
+
auth_names = opts[:debug_auth_names] || ['basicAuth']
|
|
81
|
+
|
|
82
|
+
new_options = opts.merge(
|
|
83
|
+
:operation => :"RemotesMavenApi.add_role",
|
|
84
|
+
:header_params => header_params,
|
|
85
|
+
:query_params => query_params,
|
|
86
|
+
:form_params => form_params,
|
|
87
|
+
:body => post_body,
|
|
88
|
+
:auth_names => auth_names,
|
|
89
|
+
:return_type => return_type
|
|
90
|
+
)
|
|
91
|
+
|
|
92
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
93
|
+
if @api_client.config.debugging
|
|
94
|
+
@api_client.config.logger.debug "API called: RemotesMavenApi#add_role\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
95
|
+
end
|
|
96
|
+
return data, status_code, headers
|
|
97
|
+
end
|
|
98
|
+
|
|
22
99
|
# Create a maven remote
|
|
23
100
|
# A ViewSet for MavenRemote.
|
|
24
101
|
# @param maven_maven_remote [MavenMavenRemote]
|
|
@@ -298,6 +375,150 @@ module PulpMavenClient
|
|
|
298
375
|
return data, status_code, headers
|
|
299
376
|
end
|
|
300
377
|
|
|
378
|
+
# List roles
|
|
379
|
+
# List roles assigned to this object.
|
|
380
|
+
# @param maven_maven_remote_href [String]
|
|
381
|
+
# @param [Hash] opts the optional parameters
|
|
382
|
+
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
383
|
+
# @option opts [Array<String>] :fields A list of fields to include in the response.
|
|
384
|
+
# @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
|
|
385
|
+
# @return [ObjectRolesResponse]
|
|
386
|
+
def list_roles(maven_maven_remote_href, opts = {})
|
|
387
|
+
data, _status_code, _headers = list_roles_with_http_info(maven_maven_remote_href, opts)
|
|
388
|
+
data
|
|
389
|
+
end
|
|
390
|
+
|
|
391
|
+
# List roles
|
|
392
|
+
# List roles assigned to this object.
|
|
393
|
+
# @param maven_maven_remote_href [String]
|
|
394
|
+
# @param [Hash] opts the optional parameters
|
|
395
|
+
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
396
|
+
# @option opts [Array<String>] :fields A list of fields to include in the response.
|
|
397
|
+
# @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
|
|
398
|
+
# @return [Array<(ObjectRolesResponse, Integer, Hash)>] ObjectRolesResponse data, response status code and response headers
|
|
399
|
+
def list_roles_with_http_info(maven_maven_remote_href, opts = {})
|
|
400
|
+
if @api_client.config.debugging
|
|
401
|
+
@api_client.config.logger.debug 'Calling API: RemotesMavenApi.list_roles ...'
|
|
402
|
+
end
|
|
403
|
+
# verify the required parameter 'maven_maven_remote_href' is set
|
|
404
|
+
if @api_client.config.client_side_validation && maven_maven_remote_href.nil?
|
|
405
|
+
fail ArgumentError, "Missing the required parameter 'maven_maven_remote_href' when calling RemotesMavenApi.list_roles"
|
|
406
|
+
end
|
|
407
|
+
# resource path
|
|
408
|
+
local_var_path = '{maven_maven_remote_href}list_roles/'.sub('{' + 'maven_maven_remote_href' + '}', CGI.escape(maven_maven_remote_href.to_s).gsub('%2F', '/'))
|
|
409
|
+
|
|
410
|
+
# query parameters
|
|
411
|
+
query_params = opts[:query_params] || {}
|
|
412
|
+
query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :multi) if !opts[:'fields'].nil?
|
|
413
|
+
query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :multi) if !opts[:'exclude_fields'].nil?
|
|
414
|
+
|
|
415
|
+
# header parameters
|
|
416
|
+
header_params = opts[:header_params] || {}
|
|
417
|
+
# HTTP header 'Accept' (if needed)
|
|
418
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
419
|
+
header_params[:'X-Task-Diagnostics'] = @api_client.build_collection_param(opts[:'x_task_diagnostics'], :csv) if !opts[:'x_task_diagnostics'].nil?
|
|
420
|
+
|
|
421
|
+
# form parameters
|
|
422
|
+
form_params = opts[:form_params] || {}
|
|
423
|
+
|
|
424
|
+
# http body (model)
|
|
425
|
+
post_body = opts[:debug_body]
|
|
426
|
+
|
|
427
|
+
# return_type
|
|
428
|
+
return_type = opts[:debug_return_type] || 'ObjectRolesResponse'
|
|
429
|
+
|
|
430
|
+
# auth_names
|
|
431
|
+
auth_names = opts[:debug_auth_names] || ['basicAuth']
|
|
432
|
+
|
|
433
|
+
new_options = opts.merge(
|
|
434
|
+
:operation => :"RemotesMavenApi.list_roles",
|
|
435
|
+
:header_params => header_params,
|
|
436
|
+
:query_params => query_params,
|
|
437
|
+
:form_params => form_params,
|
|
438
|
+
:body => post_body,
|
|
439
|
+
:auth_names => auth_names,
|
|
440
|
+
:return_type => return_type
|
|
441
|
+
)
|
|
442
|
+
|
|
443
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
444
|
+
if @api_client.config.debugging
|
|
445
|
+
@api_client.config.logger.debug "API called: RemotesMavenApi#list_roles\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
446
|
+
end
|
|
447
|
+
return data, status_code, headers
|
|
448
|
+
end
|
|
449
|
+
|
|
450
|
+
# List user permissions
|
|
451
|
+
# List permissions available to the current user on this object.
|
|
452
|
+
# @param maven_maven_remote_href [String]
|
|
453
|
+
# @param [Hash] opts the optional parameters
|
|
454
|
+
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
455
|
+
# @option opts [Array<String>] :fields A list of fields to include in the response.
|
|
456
|
+
# @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
|
|
457
|
+
# @return [MyPermissionsResponse]
|
|
458
|
+
def my_permissions(maven_maven_remote_href, opts = {})
|
|
459
|
+
data, _status_code, _headers = my_permissions_with_http_info(maven_maven_remote_href, opts)
|
|
460
|
+
data
|
|
461
|
+
end
|
|
462
|
+
|
|
463
|
+
# List user permissions
|
|
464
|
+
# List permissions available to the current user on this object.
|
|
465
|
+
# @param maven_maven_remote_href [String]
|
|
466
|
+
# @param [Hash] opts the optional parameters
|
|
467
|
+
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
468
|
+
# @option opts [Array<String>] :fields A list of fields to include in the response.
|
|
469
|
+
# @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
|
|
470
|
+
# @return [Array<(MyPermissionsResponse, Integer, Hash)>] MyPermissionsResponse data, response status code and response headers
|
|
471
|
+
def my_permissions_with_http_info(maven_maven_remote_href, opts = {})
|
|
472
|
+
if @api_client.config.debugging
|
|
473
|
+
@api_client.config.logger.debug 'Calling API: RemotesMavenApi.my_permissions ...'
|
|
474
|
+
end
|
|
475
|
+
# verify the required parameter 'maven_maven_remote_href' is set
|
|
476
|
+
if @api_client.config.client_side_validation && maven_maven_remote_href.nil?
|
|
477
|
+
fail ArgumentError, "Missing the required parameter 'maven_maven_remote_href' when calling RemotesMavenApi.my_permissions"
|
|
478
|
+
end
|
|
479
|
+
# resource path
|
|
480
|
+
local_var_path = '{maven_maven_remote_href}my_permissions/'.sub('{' + 'maven_maven_remote_href' + '}', CGI.escape(maven_maven_remote_href.to_s).gsub('%2F', '/'))
|
|
481
|
+
|
|
482
|
+
# query parameters
|
|
483
|
+
query_params = opts[:query_params] || {}
|
|
484
|
+
query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :multi) if !opts[:'fields'].nil?
|
|
485
|
+
query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :multi) if !opts[:'exclude_fields'].nil?
|
|
486
|
+
|
|
487
|
+
# header parameters
|
|
488
|
+
header_params = opts[:header_params] || {}
|
|
489
|
+
# HTTP header 'Accept' (if needed)
|
|
490
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
491
|
+
header_params[:'X-Task-Diagnostics'] = @api_client.build_collection_param(opts[:'x_task_diagnostics'], :csv) if !opts[:'x_task_diagnostics'].nil?
|
|
492
|
+
|
|
493
|
+
# form parameters
|
|
494
|
+
form_params = opts[:form_params] || {}
|
|
495
|
+
|
|
496
|
+
# http body (model)
|
|
497
|
+
post_body = opts[:debug_body]
|
|
498
|
+
|
|
499
|
+
# return_type
|
|
500
|
+
return_type = opts[:debug_return_type] || 'MyPermissionsResponse'
|
|
501
|
+
|
|
502
|
+
# auth_names
|
|
503
|
+
auth_names = opts[:debug_auth_names] || ['basicAuth']
|
|
504
|
+
|
|
505
|
+
new_options = opts.merge(
|
|
506
|
+
:operation => :"RemotesMavenApi.my_permissions",
|
|
507
|
+
:header_params => header_params,
|
|
508
|
+
:query_params => query_params,
|
|
509
|
+
:form_params => form_params,
|
|
510
|
+
:body => post_body,
|
|
511
|
+
:auth_names => auth_names,
|
|
512
|
+
:return_type => return_type
|
|
513
|
+
)
|
|
514
|
+
|
|
515
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
516
|
+
if @api_client.config.debugging
|
|
517
|
+
@api_client.config.logger.debug "API called: RemotesMavenApi#my_permissions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
518
|
+
end
|
|
519
|
+
return data, status_code, headers
|
|
520
|
+
end
|
|
521
|
+
|
|
301
522
|
# Update a maven remote
|
|
302
523
|
# Update the entity partially and trigger an asynchronous task if necessary
|
|
303
524
|
# @param maven_maven_remote_href [String]
|
|
@@ -447,6 +668,83 @@ module PulpMavenClient
|
|
|
447
668
|
return data, status_code, headers
|
|
448
669
|
end
|
|
449
670
|
|
|
671
|
+
# Remove a role
|
|
672
|
+
# Remove a role for this object from users/groups.
|
|
673
|
+
# @param maven_maven_remote_href [String]
|
|
674
|
+
# @param nested_role [NestedRole]
|
|
675
|
+
# @param [Hash] opts the optional parameters
|
|
676
|
+
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
677
|
+
# @return [NestedRoleResponse]
|
|
678
|
+
def remove_role(maven_maven_remote_href, nested_role, opts = {})
|
|
679
|
+
data, _status_code, _headers = remove_role_with_http_info(maven_maven_remote_href, nested_role, opts)
|
|
680
|
+
data
|
|
681
|
+
end
|
|
682
|
+
|
|
683
|
+
# Remove a role
|
|
684
|
+
# Remove a role for this object from users/groups.
|
|
685
|
+
# @param maven_maven_remote_href [String]
|
|
686
|
+
# @param nested_role [NestedRole]
|
|
687
|
+
# @param [Hash] opts the optional parameters
|
|
688
|
+
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
689
|
+
# @return [Array<(NestedRoleResponse, Integer, Hash)>] NestedRoleResponse data, response status code and response headers
|
|
690
|
+
def remove_role_with_http_info(maven_maven_remote_href, nested_role, opts = {})
|
|
691
|
+
if @api_client.config.debugging
|
|
692
|
+
@api_client.config.logger.debug 'Calling API: RemotesMavenApi.remove_role ...'
|
|
693
|
+
end
|
|
694
|
+
# verify the required parameter 'maven_maven_remote_href' is set
|
|
695
|
+
if @api_client.config.client_side_validation && maven_maven_remote_href.nil?
|
|
696
|
+
fail ArgumentError, "Missing the required parameter 'maven_maven_remote_href' when calling RemotesMavenApi.remove_role"
|
|
697
|
+
end
|
|
698
|
+
# verify the required parameter 'nested_role' is set
|
|
699
|
+
if @api_client.config.client_side_validation && nested_role.nil?
|
|
700
|
+
fail ArgumentError, "Missing the required parameter 'nested_role' when calling RemotesMavenApi.remove_role"
|
|
701
|
+
end
|
|
702
|
+
# resource path
|
|
703
|
+
local_var_path = '{maven_maven_remote_href}remove_role/'.sub('{' + 'maven_maven_remote_href' + '}', CGI.escape(maven_maven_remote_href.to_s).gsub('%2F', '/'))
|
|
704
|
+
|
|
705
|
+
# query parameters
|
|
706
|
+
query_params = opts[:query_params] || {}
|
|
707
|
+
|
|
708
|
+
# header parameters
|
|
709
|
+
header_params = opts[:header_params] || {}
|
|
710
|
+
# HTTP header 'Accept' (if needed)
|
|
711
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
712
|
+
# HTTP header 'Content-Type'
|
|
713
|
+
content_type = @api_client.select_header_content_type(['application/json', 'application/x-www-form-urlencoded', 'multipart/form-data'])
|
|
714
|
+
if !content_type.nil?
|
|
715
|
+
header_params['Content-Type'] = content_type
|
|
716
|
+
end
|
|
717
|
+
header_params[:'X-Task-Diagnostics'] = @api_client.build_collection_param(opts[:'x_task_diagnostics'], :csv) if !opts[:'x_task_diagnostics'].nil?
|
|
718
|
+
|
|
719
|
+
# form parameters
|
|
720
|
+
form_params = opts[:form_params] || {}
|
|
721
|
+
|
|
722
|
+
# http body (model)
|
|
723
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(nested_role)
|
|
724
|
+
|
|
725
|
+
# return_type
|
|
726
|
+
return_type = opts[:debug_return_type] || 'NestedRoleResponse'
|
|
727
|
+
|
|
728
|
+
# auth_names
|
|
729
|
+
auth_names = opts[:debug_auth_names] || ['basicAuth']
|
|
730
|
+
|
|
731
|
+
new_options = opts.merge(
|
|
732
|
+
:operation => :"RemotesMavenApi.remove_role",
|
|
733
|
+
:header_params => header_params,
|
|
734
|
+
:query_params => query_params,
|
|
735
|
+
:form_params => form_params,
|
|
736
|
+
:body => post_body,
|
|
737
|
+
:auth_names => auth_names,
|
|
738
|
+
:return_type => return_type
|
|
739
|
+
)
|
|
740
|
+
|
|
741
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
742
|
+
if @api_client.config.debugging
|
|
743
|
+
@api_client.config.logger.debug "API called: RemotesMavenApi#remove_role\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
744
|
+
end
|
|
745
|
+
return data, status_code, headers
|
|
746
|
+
end
|
|
747
|
+
|
|
450
748
|
# Set a label
|
|
451
749
|
# Set a single pulp_label on the object to a specific value or null.
|
|
452
750
|
# @param maven_maven_remote_href [String]
|