pulp_deb_client 2.0.0b2
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 +7 -0
- data/Gemfile +9 -0
- data/README.md +163 -0
- data/Rakefile +10 -0
- data/docs/AsyncOperationResponse.md +17 -0
- data/docs/ContentGenericContentsApi.md +194 -0
- data/docs/ContentInstallerFileIndexApi.md +186 -0
- data/docs/ContentInstallerPackagesApi.md +194 -0
- data/docs/ContentPackageIndexApi.md +186 -0
- data/docs/ContentPackagesApi.md +194 -0
- data/docs/ContentReleasesApi.md +186 -0
- data/docs/DebDistribution.md +29 -0
- data/docs/DebPublication.md +31 -0
- data/docs/DebRemote.md +57 -0
- data/docs/DistributionsAptApi.md +358 -0
- data/docs/GenericContent.md +41 -0
- data/docs/InlineResponse200.md +23 -0
- data/docs/InlineResponse2001.md +23 -0
- data/docs/InlineResponse2002.md +23 -0
- data/docs/InlineResponse2003.md +23 -0
- data/docs/InlineResponse2004.md +23 -0
- data/docs/InlineResponse2005.md +23 -0
- data/docs/InlineResponse2006.md +23 -0
- data/docs/InlineResponse2007.md +23 -0
- data/docs/InlineResponse2008.md +23 -0
- data/docs/InlineResponse2009.md +23 -0
- data/docs/InstallerFileIndex.md +31 -0
- data/docs/InstallerPackage.md +99 -0
- data/docs/Package.md +99 -0
- data/docs/PackageIndex.md +31 -0
- data/docs/PublicationsAptApi.md +235 -0
- data/docs/PublicationsVerbatimApi.md +235 -0
- data/docs/Release.md +31 -0
- data/docs/RemotesAptApi.md +417 -0
- data/docs/RepositorySyncURL.md +19 -0
- data/docs/VerbatimPublication.md +27 -0
- data/git_push.sh +58 -0
- data/lib/pulp_deb_client/api/content_generic_contents_api.rb +239 -0
- data/lib/pulp_deb_client/api/content_installer_file_index_api.rb +225 -0
- data/lib/pulp_deb_client/api/content_installer_packages_api.rb +235 -0
- data/lib/pulp_deb_client/api/content_package_index_api.rb +225 -0
- data/lib/pulp_deb_client/api/content_packages_api.rb +235 -0
- data/lib/pulp_deb_client/api/content_releases_api.rb +225 -0
- data/lib/pulp_deb_client/api/distributions_apt_api.rb +436 -0
- data/lib/pulp_deb_client/api/publications_apt_api.rb +279 -0
- data/lib/pulp_deb_client/api/publications_verbatim_api.rb +279 -0
- data/lib/pulp_deb_client/api/remotes_apt_api.rb +510 -0
- data/lib/pulp_deb_client/api_client.rb +402 -0
- data/lib/pulp_deb_client/api_error.rb +57 -0
- data/lib/pulp_deb_client/configuration.rb +243 -0
- data/lib/pulp_deb_client/models/async_operation_response.rb +202 -0
- data/lib/pulp_deb_client/models/deb_distribution.rb +337 -0
- data/lib/pulp_deb_client/models/deb_publication.rb +282 -0
- data/lib/pulp_deb_client/models/deb_remote.rb +653 -0
- data/lib/pulp_deb_client/models/generic_content.rb +444 -0
- data/lib/pulp_deb_client/models/inline_response200.rb +235 -0
- data/lib/pulp_deb_client/models/inline_response2001.rb +235 -0
- data/lib/pulp_deb_client/models/inline_response2002.rb +235 -0
- data/lib/pulp_deb_client/models/inline_response2003.rb +235 -0
- data/lib/pulp_deb_client/models/inline_response2004.rb +235 -0
- data/lib/pulp_deb_client/models/inline_response2005.rb +235 -0
- data/lib/pulp_deb_client/models/inline_response2006.rb +235 -0
- data/lib/pulp_deb_client/models/inline_response2007.rb +235 -0
- data/lib/pulp_deb_client/models/inline_response2008.rb +235 -0
- data/lib/pulp_deb_client/models/inline_response2009.rb +235 -0
- data/lib/pulp_deb_client/models/installer_file_index.rb +355 -0
- data/lib/pulp_deb_client/models/installer_package.rb +1101 -0
- data/lib/pulp_deb_client/models/package.rb +1101 -0
- data/lib/pulp_deb_client/models/package_index.rb +355 -0
- data/lib/pulp_deb_client/models/release.rb +356 -0
- data/lib/pulp_deb_client/models/repository_sync_url.rb +214 -0
- data/lib/pulp_deb_client/models/verbatim_publication.rb +258 -0
- data/lib/pulp_deb_client/version.rb +15 -0
- data/lib/pulp_deb_client.rb +71 -0
- data/pulp_deb_client.gemspec +39 -0
- data/spec/api/content_generic_contents_api_spec.rb +80 -0
- data/spec/api/content_installer_file_index_api_spec.rb +77 -0
- data/spec/api/content_installer_packages_api_spec.rb +80 -0
- data/spec/api/content_package_index_api_spec.rb +77 -0
- data/spec/api/content_packages_api_spec.rb +80 -0
- data/spec/api/content_releases_api_spec.rb +77 -0
- data/spec/api/distributions_apt_api_spec.rb +118 -0
- data/spec/api/publications_apt_api_spec.rb +87 -0
- data/spec/api/publications_verbatim_api_spec.rb +87 -0
- data/spec/api/remotes_apt_api_spec.rb +132 -0
- data/spec/api_client_spec.rb +188 -0
- data/spec/configuration_spec.rb +42 -0
- data/spec/models/async_operation_response_spec.rb +41 -0
- data/spec/models/deb_distribution_spec.rb +77 -0
- data/spec/models/deb_publication_spec.rb +83 -0
- data/spec/models/deb_remote_spec.rb +165 -0
- data/spec/models/generic_content_spec.rb +113 -0
- data/spec/models/inline_response2001_spec.rb +59 -0
- data/spec/models/inline_response2002_spec.rb +59 -0
- data/spec/models/inline_response2003_spec.rb +59 -0
- data/spec/models/inline_response2004_spec.rb +59 -0
- data/spec/models/inline_response2005_spec.rb +59 -0
- data/spec/models/inline_response2006_spec.rb +59 -0
- data/spec/models/inline_response2007_spec.rb +59 -0
- data/spec/models/inline_response2008_spec.rb +59 -0
- data/spec/models/inline_response2009_spec.rb +59 -0
- data/spec/models/inline_response200_spec.rb +59 -0
- data/spec/models/installer_file_index_spec.rb +83 -0
- data/spec/models/installer_package_spec.rb +287 -0
- data/spec/models/package_index_spec.rb +83 -0
- data/spec/models/package_spec.rb +287 -0
- data/spec/models/release_spec.rb +83 -0
- data/spec/models/repository_sync_url_spec.rb +47 -0
- data/spec/models/verbatim_publication_spec.rb +71 -0
- data/spec/spec_helper.rb +111 -0
- metadata +242 -0
|
@@ -0,0 +1,235 @@
|
|
|
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.1.3-SNAPSHOT
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'cgi'
|
|
14
|
+
|
|
15
|
+
module PulpDebClient
|
|
16
|
+
class ContentPackagesApi
|
|
17
|
+
attr_accessor :api_client
|
|
18
|
+
|
|
19
|
+
def initialize(api_client = ApiClient.default)
|
|
20
|
+
@api_client = api_client
|
|
21
|
+
end
|
|
22
|
+
# Create a package
|
|
23
|
+
# Trigger an asynchronous task to create content,optionally create new repository version.
|
|
24
|
+
# @param [Hash] opts the optional parameters
|
|
25
|
+
# @option opts [String] :artifact Artifact file representing the physical content
|
|
26
|
+
# @option opts [String] :relative_path Path where the artifact is located relative to distributions base_path
|
|
27
|
+
# @option opts [File] :file An uploaded file that should be turned into the artifact of the content unit.
|
|
28
|
+
# @option opts [String] :repository A URI of a repository the new content unit should be associated with.
|
|
29
|
+
# @return [AsyncOperationResponse]
|
|
30
|
+
def create(opts = {})
|
|
31
|
+
data, _status_code, _headers = create_with_http_info(opts)
|
|
32
|
+
data
|
|
33
|
+
end
|
|
34
|
+
|
|
35
|
+
# Create a package
|
|
36
|
+
# Trigger an asynchronous task to create content,optionally create new repository version.
|
|
37
|
+
# @param [Hash] opts the optional parameters
|
|
38
|
+
# @option opts [String] :artifact Artifact file representing the physical content
|
|
39
|
+
# @option opts [String] :relative_path Path where the artifact is located relative to distributions base_path
|
|
40
|
+
# @option opts [File] :file An uploaded file that should be turned into the artifact of the content unit.
|
|
41
|
+
# @option opts [String] :repository A URI of a repository the new content unit should be associated with.
|
|
42
|
+
# @return [Array<(AsyncOperationResponse, Integer, Hash)>] AsyncOperationResponse data, response status code and response headers
|
|
43
|
+
def create_with_http_info(opts = {})
|
|
44
|
+
if @api_client.config.debugging
|
|
45
|
+
@api_client.config.logger.debug 'Calling API: ContentPackagesApi.create ...'
|
|
46
|
+
end
|
|
47
|
+
if @api_client.config.client_side_validation && !opts[:'relative_path'].nil? && opts[:'relative_path'].to_s.length < 1
|
|
48
|
+
fail ArgumentError, 'invalid value for "opts[:"relative_path"]" when calling ContentPackagesApi.create, the character length must be great than or equal to 1.'
|
|
49
|
+
end
|
|
50
|
+
|
|
51
|
+
# resource path
|
|
52
|
+
local_var_path = '/pulp/api/v3/content/deb/packages/'
|
|
53
|
+
|
|
54
|
+
# query parameters
|
|
55
|
+
query_params = opts[:query_params] || {}
|
|
56
|
+
|
|
57
|
+
# header parameters
|
|
58
|
+
header_params = opts[:header_params] || {}
|
|
59
|
+
# HTTP header 'Accept' (if needed)
|
|
60
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
|
61
|
+
# HTTP header 'Content-Type'
|
|
62
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data', 'application/x-www-form-urlencoded'])
|
|
63
|
+
|
|
64
|
+
# form parameters
|
|
65
|
+
form_params = opts[:form_params] || {}
|
|
66
|
+
form_params['artifact'] = opts[:'artifact'] if !opts[:'artifact'].nil?
|
|
67
|
+
form_params['relative_path'] = opts[:'relative_path'] if !opts[:'relative_path'].nil?
|
|
68
|
+
form_params['file'] = opts[:'file'] if !opts[:'file'].nil?
|
|
69
|
+
form_params['repository'] = opts[:'repository'] if !opts[:'repository'].nil?
|
|
70
|
+
|
|
71
|
+
# http body (model)
|
|
72
|
+
post_body = opts[:body]
|
|
73
|
+
|
|
74
|
+
# return_type
|
|
75
|
+
return_type = opts[:return_type] || 'AsyncOperationResponse'
|
|
76
|
+
|
|
77
|
+
# auth_names
|
|
78
|
+
auth_names = opts[:auth_names] || ['Basic']
|
|
79
|
+
|
|
80
|
+
new_options = opts.merge(
|
|
81
|
+
:header_params => header_params,
|
|
82
|
+
:query_params => query_params,
|
|
83
|
+
:form_params => form_params,
|
|
84
|
+
:body => post_body,
|
|
85
|
+
:auth_names => auth_names,
|
|
86
|
+
:return_type => return_type
|
|
87
|
+
)
|
|
88
|
+
|
|
89
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
90
|
+
if @api_client.config.debugging
|
|
91
|
+
@api_client.config.logger.debug "API called: ContentPackagesApi#create\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
92
|
+
end
|
|
93
|
+
return data, status_code, headers
|
|
94
|
+
end
|
|
95
|
+
|
|
96
|
+
# List packages
|
|
97
|
+
# A ViewSet for Package.
|
|
98
|
+
# @param [Hash] opts the optional parameters
|
|
99
|
+
# @option opts [String] :repository_version Repository Version referenced by HREF
|
|
100
|
+
# @option opts [String] :repository_version_added Repository Version referenced by HREF
|
|
101
|
+
# @option opts [String] :repository_version_removed Repository Version referenced by HREF
|
|
102
|
+
# @option opts [Integer] :limit Number of results to return per page.
|
|
103
|
+
# @option opts [Integer] :offset The initial index from which to return the results.
|
|
104
|
+
# @option opts [String] :fields A list of fields to include in the response.
|
|
105
|
+
# @return [InlineResponse2004]
|
|
106
|
+
def list(opts = {})
|
|
107
|
+
data, _status_code, _headers = list_with_http_info(opts)
|
|
108
|
+
data
|
|
109
|
+
end
|
|
110
|
+
|
|
111
|
+
# List packages
|
|
112
|
+
# A ViewSet for Package.
|
|
113
|
+
# @param [Hash] opts the optional parameters
|
|
114
|
+
# @option opts [String] :repository_version Repository Version referenced by HREF
|
|
115
|
+
# @option opts [String] :repository_version_added Repository Version referenced by HREF
|
|
116
|
+
# @option opts [String] :repository_version_removed Repository Version referenced by HREF
|
|
117
|
+
# @option opts [Integer] :limit Number of results to return per page.
|
|
118
|
+
# @option opts [Integer] :offset The initial index from which to return the results.
|
|
119
|
+
# @option opts [String] :fields A list of fields to include in the response.
|
|
120
|
+
# @return [Array<(InlineResponse2004, Integer, Hash)>] InlineResponse2004 data, response status code and response headers
|
|
121
|
+
def list_with_http_info(opts = {})
|
|
122
|
+
if @api_client.config.debugging
|
|
123
|
+
@api_client.config.logger.debug 'Calling API: ContentPackagesApi.list ...'
|
|
124
|
+
end
|
|
125
|
+
# resource path
|
|
126
|
+
local_var_path = '/pulp/api/v3/content/deb/packages/'
|
|
127
|
+
|
|
128
|
+
# query parameters
|
|
129
|
+
query_params = opts[:query_params] || {}
|
|
130
|
+
query_params[:'repository_version'] = opts[:'repository_version'] if !opts[:'repository_version'].nil?
|
|
131
|
+
query_params[:'repository_version_added'] = opts[:'repository_version_added'] if !opts[:'repository_version_added'].nil?
|
|
132
|
+
query_params[:'repository_version_removed'] = opts[:'repository_version_removed'] if !opts[:'repository_version_removed'].nil?
|
|
133
|
+
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
|
134
|
+
query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
|
|
135
|
+
query_params[:'fields'] = opts[:'fields'] if !opts[:'fields'].nil?
|
|
136
|
+
|
|
137
|
+
# header parameters
|
|
138
|
+
header_params = opts[:header_params] || {}
|
|
139
|
+
# HTTP header 'Accept' (if needed)
|
|
140
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
|
141
|
+
|
|
142
|
+
# form parameters
|
|
143
|
+
form_params = opts[:form_params] || {}
|
|
144
|
+
|
|
145
|
+
# http body (model)
|
|
146
|
+
post_body = opts[:body]
|
|
147
|
+
|
|
148
|
+
# return_type
|
|
149
|
+
return_type = opts[:return_type] || 'InlineResponse2004'
|
|
150
|
+
|
|
151
|
+
# auth_names
|
|
152
|
+
auth_names = opts[:auth_names] || ['Basic']
|
|
153
|
+
|
|
154
|
+
new_options = opts.merge(
|
|
155
|
+
:header_params => header_params,
|
|
156
|
+
:query_params => query_params,
|
|
157
|
+
:form_params => form_params,
|
|
158
|
+
:body => post_body,
|
|
159
|
+
:auth_names => auth_names,
|
|
160
|
+
:return_type => return_type
|
|
161
|
+
)
|
|
162
|
+
|
|
163
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
164
|
+
if @api_client.config.debugging
|
|
165
|
+
@api_client.config.logger.debug "API called: ContentPackagesApi#list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
166
|
+
end
|
|
167
|
+
return data, status_code, headers
|
|
168
|
+
end
|
|
169
|
+
|
|
170
|
+
# Inspect a package
|
|
171
|
+
# A ViewSet for Package.
|
|
172
|
+
# @param package_href [String] URI of Package. e.g.: /pulp/api/v3/content/deb/packages/1/
|
|
173
|
+
# @param [Hash] opts the optional parameters
|
|
174
|
+
# @option opts [String] :fields A list of fields to include in the response.
|
|
175
|
+
# @return [Package]
|
|
176
|
+
def read(package_href, opts = {})
|
|
177
|
+
data, _status_code, _headers = read_with_http_info(package_href, opts)
|
|
178
|
+
data
|
|
179
|
+
end
|
|
180
|
+
|
|
181
|
+
# Inspect a package
|
|
182
|
+
# A ViewSet for Package.
|
|
183
|
+
# @param package_href [String] URI of Package. e.g.: /pulp/api/v3/content/deb/packages/1/
|
|
184
|
+
# @param [Hash] opts the optional parameters
|
|
185
|
+
# @option opts [String] :fields A list of fields to include in the response.
|
|
186
|
+
# @return [Array<(Package, Integer, Hash)>] Package data, response status code and response headers
|
|
187
|
+
def read_with_http_info(package_href, opts = {})
|
|
188
|
+
if @api_client.config.debugging
|
|
189
|
+
@api_client.config.logger.debug 'Calling API: ContentPackagesApi.read ...'
|
|
190
|
+
end
|
|
191
|
+
# verify the required parameter 'package_href' is set
|
|
192
|
+
if @api_client.config.client_side_validation && package_href.nil?
|
|
193
|
+
fail ArgumentError, "Missing the required parameter 'package_href' when calling ContentPackagesApi.read"
|
|
194
|
+
end
|
|
195
|
+
# resource path
|
|
196
|
+
local_var_path = '{package_href}'.sub('{' + 'package_href' + '}', CGI.escape(package_href.to_s).gsub('%2F', '/'))
|
|
197
|
+
|
|
198
|
+
# query parameters
|
|
199
|
+
query_params = opts[:query_params] || {}
|
|
200
|
+
query_params[:'fields'] = opts[:'fields'] if !opts[:'fields'].nil?
|
|
201
|
+
|
|
202
|
+
# header parameters
|
|
203
|
+
header_params = opts[:header_params] || {}
|
|
204
|
+
# HTTP header 'Accept' (if needed)
|
|
205
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
|
206
|
+
|
|
207
|
+
# form parameters
|
|
208
|
+
form_params = opts[:form_params] || {}
|
|
209
|
+
|
|
210
|
+
# http body (model)
|
|
211
|
+
post_body = opts[:body]
|
|
212
|
+
|
|
213
|
+
# return_type
|
|
214
|
+
return_type = opts[:return_type] || 'Package'
|
|
215
|
+
|
|
216
|
+
# auth_names
|
|
217
|
+
auth_names = opts[:auth_names] || ['Basic']
|
|
218
|
+
|
|
219
|
+
new_options = opts.merge(
|
|
220
|
+
:header_params => header_params,
|
|
221
|
+
:query_params => query_params,
|
|
222
|
+
:form_params => form_params,
|
|
223
|
+
:body => post_body,
|
|
224
|
+
:auth_names => auth_names,
|
|
225
|
+
:return_type => return_type
|
|
226
|
+
)
|
|
227
|
+
|
|
228
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
229
|
+
if @api_client.config.debugging
|
|
230
|
+
@api_client.config.logger.debug "API called: ContentPackagesApi#read\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
231
|
+
end
|
|
232
|
+
return data, status_code, headers
|
|
233
|
+
end
|
|
234
|
+
end
|
|
235
|
+
end
|
|
@@ -0,0 +1,225 @@
|
|
|
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.1.3-SNAPSHOT
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'cgi'
|
|
14
|
+
|
|
15
|
+
module PulpDebClient
|
|
16
|
+
class ContentReleasesApi
|
|
17
|
+
attr_accessor :api_client
|
|
18
|
+
|
|
19
|
+
def initialize(api_client = ApiClient.default)
|
|
20
|
+
@api_client = api_client
|
|
21
|
+
end
|
|
22
|
+
# Create a release
|
|
23
|
+
# A ViewSet for Release.
|
|
24
|
+
# @param data [Release]
|
|
25
|
+
# @param [Hash] opts the optional parameters
|
|
26
|
+
# @return [Release]
|
|
27
|
+
def create(data, opts = {})
|
|
28
|
+
data, _status_code, _headers = create_with_http_info(data, opts)
|
|
29
|
+
data
|
|
30
|
+
end
|
|
31
|
+
|
|
32
|
+
# Create a release
|
|
33
|
+
# A ViewSet for Release.
|
|
34
|
+
# @param data [Release]
|
|
35
|
+
# @param [Hash] opts the optional parameters
|
|
36
|
+
# @return [Array<(Release, Integer, Hash)>] Release 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: ContentReleasesApi.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 ContentReleasesApi.create"
|
|
44
|
+
end
|
|
45
|
+
# resource path
|
|
46
|
+
local_var_path = '/pulp/api/v3/content/deb/releases/'
|
|
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] || 'Release'
|
|
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: ContentReleasesApi#create\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
82
|
+
end
|
|
83
|
+
return data, status_code, headers
|
|
84
|
+
end
|
|
85
|
+
|
|
86
|
+
# List releases
|
|
87
|
+
# A ViewSet for Release.
|
|
88
|
+
# @param [Hash] opts the optional parameters
|
|
89
|
+
# @option opts [String] :repository_version Repository Version referenced by HREF
|
|
90
|
+
# @option opts [String] :repository_version_added Repository Version referenced by HREF
|
|
91
|
+
# @option opts [String] :repository_version_removed Repository Version referenced by HREF
|
|
92
|
+
# @option opts [Integer] :limit Number of results to return per page.
|
|
93
|
+
# @option opts [Integer] :offset The initial index from which to return the results.
|
|
94
|
+
# @option opts [String] :fields A list of fields to include in the response.
|
|
95
|
+
# @return [InlineResponse2005]
|
|
96
|
+
def list(opts = {})
|
|
97
|
+
data, _status_code, _headers = list_with_http_info(opts)
|
|
98
|
+
data
|
|
99
|
+
end
|
|
100
|
+
|
|
101
|
+
# List releases
|
|
102
|
+
# A ViewSet for Release.
|
|
103
|
+
# @param [Hash] opts the optional parameters
|
|
104
|
+
# @option opts [String] :repository_version Repository Version referenced by HREF
|
|
105
|
+
# @option opts [String] :repository_version_added Repository Version referenced by HREF
|
|
106
|
+
# @option opts [String] :repository_version_removed Repository Version referenced by HREF
|
|
107
|
+
# @option opts [Integer] :limit Number of results to return per page.
|
|
108
|
+
# @option opts [Integer] :offset The initial index from which to return the results.
|
|
109
|
+
# @option opts [String] :fields A list of fields to include in the response.
|
|
110
|
+
# @return [Array<(InlineResponse2005, Integer, Hash)>] InlineResponse2005 data, response status code and response headers
|
|
111
|
+
def list_with_http_info(opts = {})
|
|
112
|
+
if @api_client.config.debugging
|
|
113
|
+
@api_client.config.logger.debug 'Calling API: ContentReleasesApi.list ...'
|
|
114
|
+
end
|
|
115
|
+
# resource path
|
|
116
|
+
local_var_path = '/pulp/api/v3/content/deb/releases/'
|
|
117
|
+
|
|
118
|
+
# query parameters
|
|
119
|
+
query_params = opts[:query_params] || {}
|
|
120
|
+
query_params[:'repository_version'] = opts[:'repository_version'] if !opts[:'repository_version'].nil?
|
|
121
|
+
query_params[:'repository_version_added'] = opts[:'repository_version_added'] if !opts[:'repository_version_added'].nil?
|
|
122
|
+
query_params[:'repository_version_removed'] = opts[:'repository_version_removed'] if !opts[:'repository_version_removed'].nil?
|
|
123
|
+
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
|
124
|
+
query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
|
|
125
|
+
query_params[:'fields'] = opts[:'fields'] if !opts[:'fields'].nil?
|
|
126
|
+
|
|
127
|
+
# header parameters
|
|
128
|
+
header_params = opts[:header_params] || {}
|
|
129
|
+
# HTTP header 'Accept' (if needed)
|
|
130
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
|
131
|
+
|
|
132
|
+
# form parameters
|
|
133
|
+
form_params = opts[:form_params] || {}
|
|
134
|
+
|
|
135
|
+
# http body (model)
|
|
136
|
+
post_body = opts[:body]
|
|
137
|
+
|
|
138
|
+
# return_type
|
|
139
|
+
return_type = opts[:return_type] || 'InlineResponse2005'
|
|
140
|
+
|
|
141
|
+
# auth_names
|
|
142
|
+
auth_names = opts[:auth_names] || ['Basic']
|
|
143
|
+
|
|
144
|
+
new_options = opts.merge(
|
|
145
|
+
:header_params => header_params,
|
|
146
|
+
:query_params => query_params,
|
|
147
|
+
:form_params => form_params,
|
|
148
|
+
:body => post_body,
|
|
149
|
+
:auth_names => auth_names,
|
|
150
|
+
:return_type => return_type
|
|
151
|
+
)
|
|
152
|
+
|
|
153
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
154
|
+
if @api_client.config.debugging
|
|
155
|
+
@api_client.config.logger.debug "API called: ContentReleasesApi#list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
156
|
+
end
|
|
157
|
+
return data, status_code, headers
|
|
158
|
+
end
|
|
159
|
+
|
|
160
|
+
# Inspect a release
|
|
161
|
+
# A ViewSet for Release.
|
|
162
|
+
# @param release_href [String] URI of Release. e.g.: /pulp/api/v3/content/deb/releases/1/
|
|
163
|
+
# @param [Hash] opts the optional parameters
|
|
164
|
+
# @option opts [String] :fields A list of fields to include in the response.
|
|
165
|
+
# @return [Release]
|
|
166
|
+
def read(release_href, opts = {})
|
|
167
|
+
data, _status_code, _headers = read_with_http_info(release_href, opts)
|
|
168
|
+
data
|
|
169
|
+
end
|
|
170
|
+
|
|
171
|
+
# Inspect a release
|
|
172
|
+
# A ViewSet for Release.
|
|
173
|
+
# @param release_href [String] URI of Release. e.g.: /pulp/api/v3/content/deb/releases/1/
|
|
174
|
+
# @param [Hash] opts the optional parameters
|
|
175
|
+
# @option opts [String] :fields A list of fields to include in the response.
|
|
176
|
+
# @return [Array<(Release, Integer, Hash)>] Release data, response status code and response headers
|
|
177
|
+
def read_with_http_info(release_href, opts = {})
|
|
178
|
+
if @api_client.config.debugging
|
|
179
|
+
@api_client.config.logger.debug 'Calling API: ContentReleasesApi.read ...'
|
|
180
|
+
end
|
|
181
|
+
# verify the required parameter 'release_href' is set
|
|
182
|
+
if @api_client.config.client_side_validation && release_href.nil?
|
|
183
|
+
fail ArgumentError, "Missing the required parameter 'release_href' when calling ContentReleasesApi.read"
|
|
184
|
+
end
|
|
185
|
+
# resource path
|
|
186
|
+
local_var_path = '{release_href}'.sub('{' + 'release_href' + '}', CGI.escape(release_href.to_s).gsub('%2F', '/'))
|
|
187
|
+
|
|
188
|
+
# query parameters
|
|
189
|
+
query_params = opts[:query_params] || {}
|
|
190
|
+
query_params[:'fields'] = opts[:'fields'] if !opts[:'fields'].nil?
|
|
191
|
+
|
|
192
|
+
# header parameters
|
|
193
|
+
header_params = opts[:header_params] || {}
|
|
194
|
+
# HTTP header 'Accept' (if needed)
|
|
195
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
|
196
|
+
|
|
197
|
+
# form parameters
|
|
198
|
+
form_params = opts[:form_params] || {}
|
|
199
|
+
|
|
200
|
+
# http body (model)
|
|
201
|
+
post_body = opts[:body]
|
|
202
|
+
|
|
203
|
+
# return_type
|
|
204
|
+
return_type = opts[:return_type] || 'Release'
|
|
205
|
+
|
|
206
|
+
# auth_names
|
|
207
|
+
auth_names = opts[:auth_names] || ['Basic']
|
|
208
|
+
|
|
209
|
+
new_options = opts.merge(
|
|
210
|
+
:header_params => header_params,
|
|
211
|
+
:query_params => query_params,
|
|
212
|
+
:form_params => form_params,
|
|
213
|
+
:body => post_body,
|
|
214
|
+
:auth_names => auth_names,
|
|
215
|
+
:return_type => return_type
|
|
216
|
+
)
|
|
217
|
+
|
|
218
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
219
|
+
if @api_client.config.debugging
|
|
220
|
+
@api_client.config.logger.debug "API called: ContentReleasesApi#read\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
221
|
+
end
|
|
222
|
+
return data, status_code, headers
|
|
223
|
+
end
|
|
224
|
+
end
|
|
225
|
+
end
|