pulpcore_client 3.73.1 → 3.73.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -217,5 +217,153 @@ module PulpcoreClient
217
217
  end
218
218
  return data, status_code, headers
219
219
  end
220
+
221
+ # Set a label
222
+ # Set a single pulp_label on the object to a specific value or null.
223
+ # @param open_p_g_p_user_i_d_href [String]
224
+ # @param set_label [SetLabel]
225
+ # @param [Hash] opts the optional parameters
226
+ # @return [SetLabelResponse]
227
+ def set_label(open_p_g_p_user_i_d_href, set_label, opts = {})
228
+ data, _status_code, _headers = set_label_with_http_info(open_p_g_p_user_i_d_href, set_label, opts)
229
+ data
230
+ end
231
+
232
+ # Set a label
233
+ # Set a single pulp_label on the object to a specific value or null.
234
+ # @param open_p_g_p_user_i_d_href [String]
235
+ # @param set_label [SetLabel]
236
+ # @param [Hash] opts the optional parameters
237
+ # @return [Array<(SetLabelResponse, Integer, Hash)>] SetLabelResponse data, response status code and response headers
238
+ def set_label_with_http_info(open_p_g_p_user_i_d_href, set_label, opts = {})
239
+ if @api_client.config.debugging
240
+ @api_client.config.logger.debug 'Calling API: ContentOpenpgpUseridApi.set_label ...'
241
+ end
242
+ # verify the required parameter 'open_p_g_p_user_i_d_href' is set
243
+ if @api_client.config.client_side_validation && open_p_g_p_user_i_d_href.nil?
244
+ fail ArgumentError, "Missing the required parameter 'open_p_g_p_user_i_d_href' when calling ContentOpenpgpUseridApi.set_label"
245
+ end
246
+ # verify the required parameter 'set_label' is set
247
+ if @api_client.config.client_side_validation && set_label.nil?
248
+ fail ArgumentError, "Missing the required parameter 'set_label' when calling ContentOpenpgpUseridApi.set_label"
249
+ end
250
+ # resource path
251
+ local_var_path = '{open_p_g_p_user_i_d_href}set_label/'.sub('{' + 'open_p_g_p_user_i_d_href' + '}', CGI.escape(open_p_g_p_user_i_d_href.to_s).gsub('%2F', '/'))
252
+
253
+ # query parameters
254
+ query_params = opts[:query_params] || {}
255
+
256
+ # header parameters
257
+ header_params = opts[:header_params] || {}
258
+ # HTTP header 'Accept' (if needed)
259
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
260
+ # HTTP header 'Content-Type'
261
+ content_type = @api_client.select_header_content_type(['application/json', 'application/x-www-form-urlencoded', 'multipart/form-data'])
262
+ if !content_type.nil?
263
+ header_params['Content-Type'] = content_type
264
+ end
265
+
266
+ # form parameters
267
+ form_params = opts[:form_params] || {}
268
+
269
+ # http body (model)
270
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(set_label)
271
+
272
+ # return_type
273
+ return_type = opts[:debug_return_type] || 'SetLabelResponse'
274
+
275
+ # auth_names
276
+ auth_names = opts[:debug_auth_names] || ['basicAuth']
277
+
278
+ new_options = opts.merge(
279
+ :operation => :"ContentOpenpgpUseridApi.set_label",
280
+ :header_params => header_params,
281
+ :query_params => query_params,
282
+ :form_params => form_params,
283
+ :body => post_body,
284
+ :auth_names => auth_names,
285
+ :return_type => return_type
286
+ )
287
+
288
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
289
+ if @api_client.config.debugging
290
+ @api_client.config.logger.debug "API called: ContentOpenpgpUseridApi#set_label\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
291
+ end
292
+ return data, status_code, headers
293
+ end
294
+
295
+ # Unset a label
296
+ # Unset a single pulp_label on the object.
297
+ # @param open_p_g_p_user_i_d_href [String]
298
+ # @param unset_label [UnsetLabel]
299
+ # @param [Hash] opts the optional parameters
300
+ # @return [UnsetLabelResponse]
301
+ def unset_label(open_p_g_p_user_i_d_href, unset_label, opts = {})
302
+ data, _status_code, _headers = unset_label_with_http_info(open_p_g_p_user_i_d_href, unset_label, opts)
303
+ data
304
+ end
305
+
306
+ # Unset a label
307
+ # Unset a single pulp_label on the object.
308
+ # @param open_p_g_p_user_i_d_href [String]
309
+ # @param unset_label [UnsetLabel]
310
+ # @param [Hash] opts the optional parameters
311
+ # @return [Array<(UnsetLabelResponse, Integer, Hash)>] UnsetLabelResponse data, response status code and response headers
312
+ def unset_label_with_http_info(open_p_g_p_user_i_d_href, unset_label, opts = {})
313
+ if @api_client.config.debugging
314
+ @api_client.config.logger.debug 'Calling API: ContentOpenpgpUseridApi.unset_label ...'
315
+ end
316
+ # verify the required parameter 'open_p_g_p_user_i_d_href' is set
317
+ if @api_client.config.client_side_validation && open_p_g_p_user_i_d_href.nil?
318
+ fail ArgumentError, "Missing the required parameter 'open_p_g_p_user_i_d_href' when calling ContentOpenpgpUseridApi.unset_label"
319
+ end
320
+ # verify the required parameter 'unset_label' is set
321
+ if @api_client.config.client_side_validation && unset_label.nil?
322
+ fail ArgumentError, "Missing the required parameter 'unset_label' when calling ContentOpenpgpUseridApi.unset_label"
323
+ end
324
+ # resource path
325
+ local_var_path = '{open_p_g_p_user_i_d_href}unset_label/'.sub('{' + 'open_p_g_p_user_i_d_href' + '}', CGI.escape(open_p_g_p_user_i_d_href.to_s).gsub('%2F', '/'))
326
+
327
+ # query parameters
328
+ query_params = opts[:query_params] || {}
329
+
330
+ # header parameters
331
+ header_params = opts[:header_params] || {}
332
+ # HTTP header 'Accept' (if needed)
333
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
334
+ # HTTP header 'Content-Type'
335
+ content_type = @api_client.select_header_content_type(['application/json', 'application/x-www-form-urlencoded', 'multipart/form-data'])
336
+ if !content_type.nil?
337
+ header_params['Content-Type'] = content_type
338
+ end
339
+
340
+ # form parameters
341
+ form_params = opts[:form_params] || {}
342
+
343
+ # http body (model)
344
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(unset_label)
345
+
346
+ # return_type
347
+ return_type = opts[:debug_return_type] || 'UnsetLabelResponse'
348
+
349
+ # auth_names
350
+ auth_names = opts[:debug_auth_names] || ['basicAuth']
351
+
352
+ new_options = opts.merge(
353
+ :operation => :"ContentOpenpgpUseridApi.unset_label",
354
+ :header_params => header_params,
355
+ :query_params => query_params,
356
+ :form_params => form_params,
357
+ :body => post_body,
358
+ :auth_names => auth_names,
359
+ :return_type => return_type
360
+ )
361
+
362
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
363
+ if @api_client.config.debugging
364
+ @api_client.config.logger.debug "API called: ContentOpenpgpUseridApi#unset_label\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
365
+ end
366
+ return data, status_code, headers
367
+ end
220
368
  end
221
369
  end
@@ -16,15 +16,15 @@ require 'time'
16
16
  module PulpcoreClient
17
17
  # A serializer for ArtifactDistribution.
18
18
  class ArtifactDistributionResponse
19
- # The URL for accessing the publication as defined by this distribution.
20
- attr_accessor :base_url
21
-
22
19
  # Timestamp since when the distributed content served by this distribution has not changed. If equals to `null`, no guarantee is provided about content changes.
23
20
  attr_accessor :no_content_change_since
24
21
 
25
22
  # Timestamp of the last time this resource was updated. Note: for immutable resources - like content, repository versions, and publication - pulp_created and pulp_last_updated dates will be the same.
26
23
  attr_accessor :pulp_last_updated
27
24
 
25
+ # An optional content-guard.
26
+ attr_accessor :content_guard
27
+
28
28
  attr_accessor :pulp_labels
29
29
 
30
30
  # A unique name. Ex, `rawhide` and `stable`.
@@ -33,34 +33,34 @@ module PulpcoreClient
33
33
  # Whether this distribution should be shown in the content app.
34
34
  attr_accessor :hidden
35
35
 
36
- attr_accessor :pulp_href
37
-
38
- # Timestamp of creation.
39
- attr_accessor :pulp_created
40
-
41
- # An optional content-guard.
42
- attr_accessor :content_guard
43
-
44
36
  # The Pulp Resource Name (PRN).
45
37
  attr_accessor :prn
46
38
 
39
+ # The URL for accessing the publication as defined by this distribution.
40
+ attr_accessor :base_url
41
+
42
+ attr_accessor :pulp_href
43
+
47
44
  # The base (relative) path component of the published url. Avoid paths that overlap with other distribution base paths (e.g. \"foo\" and \"foo/bar\")
48
45
  attr_accessor :base_path
49
46
 
47
+ # Timestamp of creation.
48
+ attr_accessor :pulp_created
49
+
50
50
  # Attribute mapping from ruby-style variable name to JSON key.
51
51
  def self.attribute_map
52
52
  {
53
- :'base_url' => :'base_url',
54
53
  :'no_content_change_since' => :'no_content_change_since',
55
54
  :'pulp_last_updated' => :'pulp_last_updated',
55
+ :'content_guard' => :'content_guard',
56
56
  :'pulp_labels' => :'pulp_labels',
57
57
  :'name' => :'name',
58
58
  :'hidden' => :'hidden',
59
- :'pulp_href' => :'pulp_href',
60
- :'pulp_created' => :'pulp_created',
61
- :'content_guard' => :'content_guard',
62
59
  :'prn' => :'prn',
63
- :'base_path' => :'base_path'
60
+ :'base_url' => :'base_url',
61
+ :'pulp_href' => :'pulp_href',
62
+ :'base_path' => :'base_path',
63
+ :'pulp_created' => :'pulp_created'
64
64
  }
65
65
  end
66
66
 
@@ -72,17 +72,17 @@ module PulpcoreClient
72
72
  # Attribute type mapping.
73
73
  def self.openapi_types
74
74
  {
75
- :'base_url' => :'String',
76
75
  :'no_content_change_since' => :'String',
77
76
  :'pulp_last_updated' => :'Time',
77
+ :'content_guard' => :'String',
78
78
  :'pulp_labels' => :'Hash<String, String>',
79
79
  :'name' => :'String',
80
80
  :'hidden' => :'Boolean',
81
- :'pulp_href' => :'String',
82
- :'pulp_created' => :'Time',
83
- :'content_guard' => :'String',
84
81
  :'prn' => :'String',
85
- :'base_path' => :'String'
82
+ :'base_url' => :'String',
83
+ :'pulp_href' => :'String',
84
+ :'base_path' => :'String',
85
+ :'pulp_created' => :'Time'
86
86
  }
87
87
  end
88
88
 
@@ -108,10 +108,6 @@ module PulpcoreClient
108
108
  h[k.to_sym] = v
109
109
  }
110
110
 
111
- if attributes.key?(:'base_url')
112
- self.base_url = attributes[:'base_url']
113
- end
114
-
115
111
  if attributes.key?(:'no_content_change_since')
116
112
  self.no_content_change_since = attributes[:'no_content_change_since']
117
113
  end
@@ -120,6 +116,10 @@ module PulpcoreClient
120
116
  self.pulp_last_updated = attributes[:'pulp_last_updated']
121
117
  end
122
118
 
119
+ if attributes.key?(:'content_guard')
120
+ self.content_guard = attributes[:'content_guard']
121
+ end
122
+
123
123
  if attributes.key?(:'pulp_labels')
124
124
  if (value = attributes[:'pulp_labels']).is_a?(Hash)
125
125
  self.pulp_labels = value
@@ -138,20 +138,16 @@ module PulpcoreClient
138
138
  self.hidden = false
139
139
  end
140
140
 
141
- if attributes.key?(:'pulp_href')
142
- self.pulp_href = attributes[:'pulp_href']
143
- end
144
-
145
- if attributes.key?(:'pulp_created')
146
- self.pulp_created = attributes[:'pulp_created']
141
+ if attributes.key?(:'prn')
142
+ self.prn = attributes[:'prn']
147
143
  end
148
144
 
149
- if attributes.key?(:'content_guard')
150
- self.content_guard = attributes[:'content_guard']
145
+ if attributes.key?(:'base_url')
146
+ self.base_url = attributes[:'base_url']
151
147
  end
152
148
 
153
- if attributes.key?(:'prn')
154
- self.prn = attributes[:'prn']
149
+ if attributes.key?(:'pulp_href')
150
+ self.pulp_href = attributes[:'pulp_href']
155
151
  end
156
152
 
157
153
  if attributes.key?(:'base_path')
@@ -159,6 +155,10 @@ module PulpcoreClient
159
155
  else
160
156
  self.base_path = nil
161
157
  end
158
+
159
+ if attributes.key?(:'pulp_created')
160
+ self.pulp_created = attributes[:'pulp_created']
161
+ end
162
162
  end
163
163
 
164
164
  # Show invalid properties with the reasons. Usually used together with valid?
@@ -191,17 +191,17 @@ module PulpcoreClient
191
191
  def ==(o)
192
192
  return true if self.equal?(o)
193
193
  self.class == o.class &&
194
- base_url == o.base_url &&
195
194
  no_content_change_since == o.no_content_change_since &&
196
195
  pulp_last_updated == o.pulp_last_updated &&
196
+ content_guard == o.content_guard &&
197
197
  pulp_labels == o.pulp_labels &&
198
198
  name == o.name &&
199
199
  hidden == o.hidden &&
200
- pulp_href == o.pulp_href &&
201
- pulp_created == o.pulp_created &&
202
- content_guard == o.content_guard &&
203
200
  prn == o.prn &&
204
- base_path == o.base_path
201
+ base_url == o.base_url &&
202
+ pulp_href == o.pulp_href &&
203
+ base_path == o.base_path &&
204
+ pulp_created == o.pulp_created
205
205
  end
206
206
 
207
207
  # @see the `==` method
@@ -213,7 +213,7 @@ module PulpcoreClient
213
213
  # Calculates hash code according to all attributes.
214
214
  # @return [Integer] Hash code
215
215
  def hash
216
- [base_url, no_content_change_since, pulp_last_updated, pulp_labels, name, hidden, pulp_href, pulp_created, content_guard, prn, base_path].hash
216
+ [no_content_change_since, pulp_last_updated, content_guard, pulp_labels, name, hidden, prn, base_url, pulp_href, base_path, pulp_created].hash
217
217
  end
218
218
 
219
219
  # Builds the object from hash
@@ -14,7 +14,7 @@ require 'date'
14
14
  require 'time'
15
15
 
16
16
  module PulpcoreClient
17
- # Serializer for synchronously setting a label.
17
+ # Serializer for synchronously UNsetting a label.
18
18
  class UnsetLabel
19
19
  attr_accessor :key
20
20
 
@@ -14,7 +14,7 @@ require 'date'
14
14
  require 'time'
15
15
 
16
16
  module PulpcoreClient
17
- # Serializer for synchronously setting a label.
17
+ # Serializer for synchronously UNsetting a label.
18
18
  class UnsetLabelResponse
19
19
  attr_accessor :key
20
20
 
@@ -11,5 +11,5 @@ Generator version: 7.10.0
11
11
  =end
12
12
 
13
13
  module PulpcoreClient
14
- VERSION = '3.73.1'
14
+ VERSION = '3.73.2'
15
15
  end
@@ -72,4 +72,30 @@ describe 'ContentOpenpgpPublicsubkeyApi' do
72
72
  end
73
73
  end
74
74
 
75
+ # unit tests for set_label
76
+ # Set a label
77
+ # Set a single pulp_label on the object to a specific value or null.
78
+ # @param open_p_g_p_public_subkey_href
79
+ # @param set_label
80
+ # @param [Hash] opts the optional parameters
81
+ # @return [SetLabelResponse]
82
+ describe 'set_label test' do
83
+ it 'should work' do
84
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
85
+ end
86
+ end
87
+
88
+ # unit tests for unset_label
89
+ # Unset a label
90
+ # Unset a single pulp_label on the object.
91
+ # @param open_p_g_p_public_subkey_href
92
+ # @param unset_label
93
+ # @param [Hash] opts the optional parameters
94
+ # @return [UnsetLabelResponse]
95
+ describe 'unset_label test' do
96
+ it 'should work' do
97
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
98
+ end
99
+ end
100
+
75
101
  end
@@ -72,4 +72,30 @@ describe 'ContentOpenpgpSignatureApi' do
72
72
  end
73
73
  end
74
74
 
75
+ # unit tests for set_label
76
+ # Set a label
77
+ # Set a single pulp_label on the object to a specific value or null.
78
+ # @param open_p_g_p_signature_href
79
+ # @param set_label
80
+ # @param [Hash] opts the optional parameters
81
+ # @return [SetLabelResponse]
82
+ describe 'set_label test' do
83
+ it 'should work' do
84
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
85
+ end
86
+ end
87
+
88
+ # unit tests for unset_label
89
+ # Unset a label
90
+ # Unset a single pulp_label on the object.
91
+ # @param open_p_g_p_signature_href
92
+ # @param unset_label
93
+ # @param [Hash] opts the optional parameters
94
+ # @return [UnsetLabelResponse]
95
+ describe 'unset_label test' do
96
+ it 'should work' do
97
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
98
+ end
99
+ end
100
+
75
101
  end
@@ -72,4 +72,30 @@ describe 'ContentOpenpgpUserattributeApi' do
72
72
  end
73
73
  end
74
74
 
75
+ # unit tests for set_label
76
+ # Set a label
77
+ # Set a single pulp_label on the object to a specific value or null.
78
+ # @param open_p_g_p_user_attribute_href
79
+ # @param set_label
80
+ # @param [Hash] opts the optional parameters
81
+ # @return [SetLabelResponse]
82
+ describe 'set_label test' do
83
+ it 'should work' do
84
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
85
+ end
86
+ end
87
+
88
+ # unit tests for unset_label
89
+ # Unset a label
90
+ # Unset a single pulp_label on the object.
91
+ # @param open_p_g_p_user_attribute_href
92
+ # @param unset_label
93
+ # @param [Hash] opts the optional parameters
94
+ # @return [UnsetLabelResponse]
95
+ describe 'unset_label test' do
96
+ it 'should work' do
97
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
98
+ end
99
+ end
100
+
75
101
  end
@@ -80,4 +80,30 @@ describe 'ContentOpenpgpUseridApi' do
80
80
  end
81
81
  end
82
82
 
83
+ # unit tests for set_label
84
+ # Set a label
85
+ # Set a single pulp_label on the object to a specific value or null.
86
+ # @param open_p_g_p_user_i_d_href
87
+ # @param set_label
88
+ # @param [Hash] opts the optional parameters
89
+ # @return [SetLabelResponse]
90
+ describe 'set_label test' do
91
+ it 'should work' do
92
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
93
+ end
94
+ end
95
+
96
+ # unit tests for unset_label
97
+ # Unset a label
98
+ # Unset a single pulp_label on the object.
99
+ # @param open_p_g_p_user_i_d_href
100
+ # @param unset_label
101
+ # @param [Hash] opts the optional parameters
102
+ # @return [UnsetLabelResponse]
103
+ describe 'unset_label test' do
104
+ it 'should work' do
105
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
106
+ end
107
+ end
108
+
83
109
  end
@@ -27,19 +27,19 @@ describe PulpcoreClient::ArtifactDistributionResponse do
27
27
  end
28
28
  end
29
29
 
30
- describe 'test attribute "base_url"' do
30
+ describe 'test attribute "no_content_change_since"' do
31
31
  it 'should work' do
32
32
  # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
33
33
  end
34
34
  end
35
35
 
36
- describe 'test attribute "no_content_change_since"' do
36
+ describe 'test attribute "pulp_last_updated"' do
37
37
  it 'should work' do
38
38
  # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
39
39
  end
40
40
  end
41
41
 
42
- describe 'test attribute "pulp_last_updated"' do
42
+ describe 'test attribute "content_guard"' do
43
43
  it 'should work' do
44
44
  # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
45
45
  end
@@ -63,31 +63,31 @@ describe PulpcoreClient::ArtifactDistributionResponse do
63
63
  end
64
64
  end
65
65
 
66
- describe 'test attribute "pulp_href"' do
66
+ describe 'test attribute "prn"' do
67
67
  it 'should work' do
68
68
  # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
69
69
  end
70
70
  end
71
71
 
72
- describe 'test attribute "pulp_created"' do
72
+ describe 'test attribute "base_url"' do
73
73
  it 'should work' do
74
74
  # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
75
75
  end
76
76
  end
77
77
 
78
- describe 'test attribute "content_guard"' do
78
+ describe 'test attribute "pulp_href"' do
79
79
  it 'should work' do
80
80
  # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
81
81
  end
82
82
  end
83
83
 
84
- describe 'test attribute "prn"' do
84
+ describe 'test attribute "base_path"' do
85
85
  it 'should work' do
86
86
  # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
87
87
  end
88
88
  end
89
89
 
90
- describe 'test attribute "base_path"' do
90
+ describe 'test attribute "pulp_created"' do
91
91
  it 'should work' do
92
92
  # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
93
93
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pulpcore_client
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.73.1
4
+ version: 3.73.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - OpenAPI-Generator
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2025-03-06 00:00:00.000000000 Z
11
+ date: 2025-03-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday-net_http