pulp_ansible_client 0.12.0.dev1640402201 → 0.12.0.dev1640834158

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of pulp_ansible_client might be problematic. Click here for more details.

@@ -15,43 +15,21 @@ require 'date'
15
15
  module PulpAnsibleClient
16
16
  # A serializer for Git Collection Remotes.
17
17
  class AnsibleGitRemoteResponse
18
- # A unique name for this remote.
19
- attr_accessor :name
20
-
21
- # Timestamp of creation.
22
- attr_accessor :pulp_created
23
-
24
- # Maximum number of retry attempts after a download failure. If not set then the default value (3) will be used.
25
- attr_accessor :max_retries
26
-
27
- # aiohttp.ClientTimeout.total (q.v.) for download-connections. The default is null, which will cause the default from the aiohttp library to be used.
28
- attr_accessor :total_timeout
18
+ attr_accessor :pulp_href
29
19
 
30
- # A PEM encoded client certificate used for authentication.
31
- attr_accessor :client_cert
20
+ # Limits requests per second for each concurrent downloader
21
+ attr_accessor :rate_limit
32
22
 
33
23
  # A PEM encoded CA certificate used to validate the server certificate presented by the remote server.
34
24
  attr_accessor :ca_cert
35
25
 
36
- # The proxy URL. Format: scheme://host:port
37
- attr_accessor :proxy_url
38
-
39
- # Headers for aiohttp.Clientsession
40
- attr_accessor :headers
41
-
42
26
  attr_accessor :pulp_labels
43
27
 
44
- # aiohttp.ClientTimeout.connect (q.v.) for download-connections. The default is null, which will cause the default from the aiohttp library to be used.
45
- attr_accessor :connect_timeout
46
-
47
28
  # If True, TLS peer validation must be performed.
48
29
  attr_accessor :tls_validation
49
30
 
50
- # aiohttp.ClientTimeout.sock_read (q.v.) for download-connections. The default is null, which will cause the default from the aiohttp library to be used.
51
- attr_accessor :sock_read_timeout
52
-
53
- # The URL of an external content source.
54
- attr_accessor :url
31
+ # Timestamp of the most recent update of the remote.
32
+ attr_accessor :pulp_last_updated
55
33
 
56
34
  # aiohttp.ClientTimeout.sock_connect (q.v.) for download-connections. The default is null, which will cause the default from the aiohttp library to be used.
57
35
  attr_accessor :sock_connect_timeout
@@ -59,13 +37,35 @@ module PulpAnsibleClient
59
37
  # Total number of simultaneous connections. If not set then the default value will be used.
60
38
  attr_accessor :download_concurrency
61
39
 
62
- # Limits requests per second for each concurrent downloader
63
- attr_accessor :rate_limit
40
+ # aiohttp.ClientTimeout.total (q.v.) for download-connections. The default is null, which will cause the default from the aiohttp library to be used.
41
+ attr_accessor :total_timeout
64
42
 
65
- attr_accessor :pulp_href
43
+ # A unique name for this remote.
44
+ attr_accessor :name
66
45
 
67
- # Timestamp of the most recent update of the remote.
68
- attr_accessor :pulp_last_updated
46
+ # A PEM encoded client certificate used for authentication.
47
+ attr_accessor :client_cert
48
+
49
+ # aiohttp.ClientTimeout.connect (q.v.) for download-connections. The default is null, which will cause the default from the aiohttp library to be used.
50
+ attr_accessor :connect_timeout
51
+
52
+ # Headers for aiohttp.Clientsession
53
+ attr_accessor :headers
54
+
55
+ # The proxy URL. Format: scheme://host:port
56
+ attr_accessor :proxy_url
57
+
58
+ # Maximum number of retry attempts after a download failure. If not set then the default value (3) will be used.
59
+ attr_accessor :max_retries
60
+
61
+ # The URL of an external content source.
62
+ attr_accessor :url
63
+
64
+ # aiohttp.ClientTimeout.sock_read (q.v.) for download-connections. The default is null, which will cause the default from the aiohttp library to be used.
65
+ attr_accessor :sock_read_timeout
66
+
67
+ # Timestamp of creation.
68
+ attr_accessor :pulp_created
69
69
 
70
70
  # If True, only metadata about the content will be stored in Pulp. Clients will retrieve content from the remote URL.
71
71
  attr_accessor :metadata_only
@@ -76,24 +76,24 @@ module PulpAnsibleClient
76
76
  # Attribute mapping from ruby-style variable name to JSON key.
77
77
  def self.attribute_map
78
78
  {
79
- :'name' => :'name',
80
- :'pulp_created' => :'pulp_created',
81
- :'max_retries' => :'max_retries',
82
- :'total_timeout' => :'total_timeout',
83
- :'client_cert' => :'client_cert',
79
+ :'pulp_href' => :'pulp_href',
80
+ :'rate_limit' => :'rate_limit',
84
81
  :'ca_cert' => :'ca_cert',
85
- :'proxy_url' => :'proxy_url',
86
- :'headers' => :'headers',
87
82
  :'pulp_labels' => :'pulp_labels',
88
- :'connect_timeout' => :'connect_timeout',
89
83
  :'tls_validation' => :'tls_validation',
90
- :'sock_read_timeout' => :'sock_read_timeout',
91
- :'url' => :'url',
84
+ :'pulp_last_updated' => :'pulp_last_updated',
92
85
  :'sock_connect_timeout' => :'sock_connect_timeout',
93
86
  :'download_concurrency' => :'download_concurrency',
94
- :'rate_limit' => :'rate_limit',
95
- :'pulp_href' => :'pulp_href',
96
- :'pulp_last_updated' => :'pulp_last_updated',
87
+ :'total_timeout' => :'total_timeout',
88
+ :'name' => :'name',
89
+ :'client_cert' => :'client_cert',
90
+ :'connect_timeout' => :'connect_timeout',
91
+ :'headers' => :'headers',
92
+ :'proxy_url' => :'proxy_url',
93
+ :'max_retries' => :'max_retries',
94
+ :'url' => :'url',
95
+ :'sock_read_timeout' => :'sock_read_timeout',
96
+ :'pulp_created' => :'pulp_created',
97
97
  :'metadata_only' => :'metadata_only',
98
98
  :'git_ref' => :'git_ref'
99
99
  }
@@ -102,24 +102,24 @@ module PulpAnsibleClient
102
102
  # Attribute type mapping.
103
103
  def self.openapi_types
104
104
  {
105
- :'name' => :'String',
106
- :'pulp_created' => :'DateTime',
107
- :'max_retries' => :'Integer',
108
- :'total_timeout' => :'Float',
109
- :'client_cert' => :'String',
105
+ :'pulp_href' => :'String',
106
+ :'rate_limit' => :'Integer',
110
107
  :'ca_cert' => :'String',
111
- :'proxy_url' => :'String',
112
- :'headers' => :'Array<Object>',
113
108
  :'pulp_labels' => :'Object',
114
- :'connect_timeout' => :'Float',
115
109
  :'tls_validation' => :'Boolean',
116
- :'sock_read_timeout' => :'Float',
117
- :'url' => :'String',
110
+ :'pulp_last_updated' => :'DateTime',
118
111
  :'sock_connect_timeout' => :'Float',
119
112
  :'download_concurrency' => :'Integer',
120
- :'rate_limit' => :'Integer',
121
- :'pulp_href' => :'String',
122
- :'pulp_last_updated' => :'DateTime',
113
+ :'total_timeout' => :'Float',
114
+ :'name' => :'String',
115
+ :'client_cert' => :'String',
116
+ :'connect_timeout' => :'Float',
117
+ :'headers' => :'Array<Object>',
118
+ :'proxy_url' => :'String',
119
+ :'max_retries' => :'Integer',
120
+ :'url' => :'String',
121
+ :'sock_read_timeout' => :'Float',
122
+ :'pulp_created' => :'DateTime',
123
123
  :'metadata_only' => :'Boolean',
124
124
  :'git_ref' => :'String'
125
125
  }
@@ -128,16 +128,16 @@ module PulpAnsibleClient
128
128
  # List of attributes with nullable: true
129
129
  def self.openapi_nullable
130
130
  Set.new([
131
- :'max_retries',
131
+ :'rate_limit',
132
+ :'ca_cert',
133
+ :'sock_connect_timeout',
134
+ :'download_concurrency',
132
135
  :'total_timeout',
133
136
  :'client_cert',
134
- :'ca_cert',
135
- :'proxy_url',
136
137
  :'connect_timeout',
138
+ :'proxy_url',
139
+ :'max_retries',
137
140
  :'sock_read_timeout',
138
- :'sock_connect_timeout',
139
- :'download_concurrency',
140
- :'rate_limit',
141
141
  ])
142
142
  end
143
143
 
@@ -156,78 +156,78 @@ module PulpAnsibleClient
156
156
  h[k.to_sym] = v
157
157
  }
158
158
 
159
- if attributes.key?(:'name')
160
- self.name = attributes[:'name']
159
+ if attributes.key?(:'pulp_href')
160
+ self.pulp_href = attributes[:'pulp_href']
161
161
  end
162
162
 
163
- if attributes.key?(:'pulp_created')
164
- self.pulp_created = attributes[:'pulp_created']
163
+ if attributes.key?(:'rate_limit')
164
+ self.rate_limit = attributes[:'rate_limit']
165
165
  end
166
166
 
167
- if attributes.key?(:'max_retries')
168
- self.max_retries = attributes[:'max_retries']
167
+ if attributes.key?(:'ca_cert')
168
+ self.ca_cert = attributes[:'ca_cert']
169
169
  end
170
170
 
171
- if attributes.key?(:'total_timeout')
172
- self.total_timeout = attributes[:'total_timeout']
171
+ if attributes.key?(:'pulp_labels')
172
+ self.pulp_labels = attributes[:'pulp_labels']
173
173
  end
174
174
 
175
- if attributes.key?(:'client_cert')
176
- self.client_cert = attributes[:'client_cert']
175
+ if attributes.key?(:'tls_validation')
176
+ self.tls_validation = attributes[:'tls_validation']
177
177
  end
178
178
 
179
- if attributes.key?(:'ca_cert')
180
- self.ca_cert = attributes[:'ca_cert']
179
+ if attributes.key?(:'pulp_last_updated')
180
+ self.pulp_last_updated = attributes[:'pulp_last_updated']
181
181
  end
182
182
 
183
- if attributes.key?(:'proxy_url')
184
- self.proxy_url = attributes[:'proxy_url']
183
+ if attributes.key?(:'sock_connect_timeout')
184
+ self.sock_connect_timeout = attributes[:'sock_connect_timeout']
185
185
  end
186
186
 
187
- if attributes.key?(:'headers')
188
- if (value = attributes[:'headers']).is_a?(Array)
189
- self.headers = value
190
- end
187
+ if attributes.key?(:'download_concurrency')
188
+ self.download_concurrency = attributes[:'download_concurrency']
191
189
  end
192
190
 
193
- if attributes.key?(:'pulp_labels')
194
- self.pulp_labels = attributes[:'pulp_labels']
191
+ if attributes.key?(:'total_timeout')
192
+ self.total_timeout = attributes[:'total_timeout']
195
193
  end
196
194
 
197
- if attributes.key?(:'connect_timeout')
198
- self.connect_timeout = attributes[:'connect_timeout']
195
+ if attributes.key?(:'name')
196
+ self.name = attributes[:'name']
199
197
  end
200
198
 
201
- if attributes.key?(:'tls_validation')
202
- self.tls_validation = attributes[:'tls_validation']
199
+ if attributes.key?(:'client_cert')
200
+ self.client_cert = attributes[:'client_cert']
203
201
  end
204
202
 
205
- if attributes.key?(:'sock_read_timeout')
206
- self.sock_read_timeout = attributes[:'sock_read_timeout']
203
+ if attributes.key?(:'connect_timeout')
204
+ self.connect_timeout = attributes[:'connect_timeout']
207
205
  end
208
206
 
209
- if attributes.key?(:'url')
210
- self.url = attributes[:'url']
207
+ if attributes.key?(:'headers')
208
+ if (value = attributes[:'headers']).is_a?(Array)
209
+ self.headers = value
210
+ end
211
211
  end
212
212
 
213
- if attributes.key?(:'sock_connect_timeout')
214
- self.sock_connect_timeout = attributes[:'sock_connect_timeout']
213
+ if attributes.key?(:'proxy_url')
214
+ self.proxy_url = attributes[:'proxy_url']
215
215
  end
216
216
 
217
- if attributes.key?(:'download_concurrency')
218
- self.download_concurrency = attributes[:'download_concurrency']
217
+ if attributes.key?(:'max_retries')
218
+ self.max_retries = attributes[:'max_retries']
219
219
  end
220
220
 
221
- if attributes.key?(:'rate_limit')
222
- self.rate_limit = attributes[:'rate_limit']
221
+ if attributes.key?(:'url')
222
+ self.url = attributes[:'url']
223
223
  end
224
224
 
225
- if attributes.key?(:'pulp_href')
226
- self.pulp_href = attributes[:'pulp_href']
225
+ if attributes.key?(:'sock_read_timeout')
226
+ self.sock_read_timeout = attributes[:'sock_read_timeout']
227
227
  end
228
228
 
229
- if attributes.key?(:'pulp_last_updated')
230
- self.pulp_last_updated = attributes[:'pulp_last_updated']
229
+ if attributes.key?(:'pulp_created')
230
+ self.pulp_created = attributes[:'pulp_created']
231
231
  end
232
232
 
233
233
  if attributes.key?(:'metadata_only')
@@ -243,32 +243,32 @@ module PulpAnsibleClient
243
243
  # @return Array for valid properties with the reasons
244
244
  def list_invalid_properties
245
245
  invalid_properties = Array.new
246
- if @name.nil?
247
- invalid_properties.push('invalid value for "name", name cannot be nil.')
246
+ if !@sock_connect_timeout.nil? && @sock_connect_timeout < 0.0
247
+ invalid_properties.push('invalid value for "sock_connect_timeout", must be greater than or equal to 0.0.')
248
+ end
249
+
250
+ if !@download_concurrency.nil? && @download_concurrency < 1
251
+ invalid_properties.push('invalid value for "download_concurrency", must be greater than or equal to 1.')
248
252
  end
249
253
 
250
254
  if !@total_timeout.nil? && @total_timeout < 0.0
251
255
  invalid_properties.push('invalid value for "total_timeout", must be greater than or equal to 0.0.')
252
256
  end
253
257
 
254
- if !@connect_timeout.nil? && @connect_timeout < 0.0
255
- invalid_properties.push('invalid value for "connect_timeout", must be greater than or equal to 0.0.')
258
+ if @name.nil?
259
+ invalid_properties.push('invalid value for "name", name cannot be nil.')
256
260
  end
257
261
 
258
- if !@sock_read_timeout.nil? && @sock_read_timeout < 0.0
259
- invalid_properties.push('invalid value for "sock_read_timeout", must be greater than or equal to 0.0.')
262
+ if !@connect_timeout.nil? && @connect_timeout < 0.0
263
+ invalid_properties.push('invalid value for "connect_timeout", must be greater than or equal to 0.0.')
260
264
  end
261
265
 
262
266
  if @url.nil?
263
267
  invalid_properties.push('invalid value for "url", url cannot be nil.')
264
268
  end
265
269
 
266
- if !@sock_connect_timeout.nil? && @sock_connect_timeout < 0.0
267
- invalid_properties.push('invalid value for "sock_connect_timeout", must be greater than or equal to 0.0.')
268
- end
269
-
270
- if !@download_concurrency.nil? && @download_concurrency < 1
271
- invalid_properties.push('invalid value for "download_concurrency", must be greater than or equal to 1.')
270
+ if !@sock_read_timeout.nil? && @sock_read_timeout < 0.0
271
+ invalid_properties.push('invalid value for "sock_read_timeout", must be greater than or equal to 0.0.')
272
272
  end
273
273
 
274
274
  invalid_properties
@@ -277,16 +277,36 @@ module PulpAnsibleClient
277
277
  # Check to see if the all the properties in the model are valid
278
278
  # @return true if the model is valid
279
279
  def valid?
280
- return false if @name.nil?
280
+ return false if !@sock_connect_timeout.nil? && @sock_connect_timeout < 0.0
281
+ return false if !@download_concurrency.nil? && @download_concurrency < 1
281
282
  return false if !@total_timeout.nil? && @total_timeout < 0.0
283
+ return false if @name.nil?
282
284
  return false if !@connect_timeout.nil? && @connect_timeout < 0.0
283
- return false if !@sock_read_timeout.nil? && @sock_read_timeout < 0.0
284
285
  return false if @url.nil?
285
- return false if !@sock_connect_timeout.nil? && @sock_connect_timeout < 0.0
286
- return false if !@download_concurrency.nil? && @download_concurrency < 1
286
+ return false if !@sock_read_timeout.nil? && @sock_read_timeout < 0.0
287
287
  true
288
288
  end
289
289
 
290
+ # Custom attribute writer method with validation
291
+ # @param [Object] sock_connect_timeout Value to be assigned
292
+ def sock_connect_timeout=(sock_connect_timeout)
293
+ if !sock_connect_timeout.nil? && sock_connect_timeout < 0.0
294
+ fail ArgumentError, 'invalid value for "sock_connect_timeout", must be greater than or equal to 0.0.'
295
+ end
296
+
297
+ @sock_connect_timeout = sock_connect_timeout
298
+ end
299
+
300
+ # Custom attribute writer method with validation
301
+ # @param [Object] download_concurrency Value to be assigned
302
+ def download_concurrency=(download_concurrency)
303
+ if !download_concurrency.nil? && download_concurrency < 1
304
+ fail ArgumentError, 'invalid value for "download_concurrency", must be greater than or equal to 1.'
305
+ end
306
+
307
+ @download_concurrency = download_concurrency
308
+ end
309
+
290
310
  # Custom attribute writer method with validation
291
311
  # @param [Object] total_timeout Value to be assigned
292
312
  def total_timeout=(total_timeout)
@@ -317,49 +337,29 @@ module PulpAnsibleClient
317
337
  @sock_read_timeout = sock_read_timeout
318
338
  end
319
339
 
320
- # Custom attribute writer method with validation
321
- # @param [Object] sock_connect_timeout Value to be assigned
322
- def sock_connect_timeout=(sock_connect_timeout)
323
- if !sock_connect_timeout.nil? && sock_connect_timeout < 0.0
324
- fail ArgumentError, 'invalid value for "sock_connect_timeout", must be greater than or equal to 0.0.'
325
- end
326
-
327
- @sock_connect_timeout = sock_connect_timeout
328
- end
329
-
330
- # Custom attribute writer method with validation
331
- # @param [Object] download_concurrency Value to be assigned
332
- def download_concurrency=(download_concurrency)
333
- if !download_concurrency.nil? && download_concurrency < 1
334
- fail ArgumentError, 'invalid value for "download_concurrency", must be greater than or equal to 1.'
335
- end
336
-
337
- @download_concurrency = download_concurrency
338
- end
339
-
340
340
  # Checks equality by comparing each attribute.
341
341
  # @param [Object] Object to be compared
342
342
  def ==(o)
343
343
  return true if self.equal?(o)
344
344
  self.class == o.class &&
345
- name == o.name &&
346
- pulp_created == o.pulp_created &&
347
- max_retries == o.max_retries &&
348
- total_timeout == o.total_timeout &&
349
- client_cert == o.client_cert &&
345
+ pulp_href == o.pulp_href &&
346
+ rate_limit == o.rate_limit &&
350
347
  ca_cert == o.ca_cert &&
351
- proxy_url == o.proxy_url &&
352
- headers == o.headers &&
353
348
  pulp_labels == o.pulp_labels &&
354
- connect_timeout == o.connect_timeout &&
355
349
  tls_validation == o.tls_validation &&
356
- sock_read_timeout == o.sock_read_timeout &&
357
- url == o.url &&
350
+ pulp_last_updated == o.pulp_last_updated &&
358
351
  sock_connect_timeout == o.sock_connect_timeout &&
359
352
  download_concurrency == o.download_concurrency &&
360
- rate_limit == o.rate_limit &&
361
- pulp_href == o.pulp_href &&
362
- pulp_last_updated == o.pulp_last_updated &&
353
+ total_timeout == o.total_timeout &&
354
+ name == o.name &&
355
+ client_cert == o.client_cert &&
356
+ connect_timeout == o.connect_timeout &&
357
+ headers == o.headers &&
358
+ proxy_url == o.proxy_url &&
359
+ max_retries == o.max_retries &&
360
+ url == o.url &&
361
+ sock_read_timeout == o.sock_read_timeout &&
362
+ pulp_created == o.pulp_created &&
363
363
  metadata_only == o.metadata_only &&
364
364
  git_ref == o.git_ref
365
365
  end
@@ -373,7 +373,7 @@ module PulpAnsibleClient
373
373
  # Calculates hash code according to all attributes.
374
374
  # @return [Integer] Hash code
375
375
  def hash
376
- [name, pulp_created, max_retries, total_timeout, client_cert, ca_cert, proxy_url, headers, pulp_labels, connect_timeout, tls_validation, sock_read_timeout, url, sock_connect_timeout, download_concurrency, rate_limit, pulp_href, pulp_last_updated, metadata_only, git_ref].hash
376
+ [pulp_href, rate_limit, ca_cert, pulp_labels, tls_validation, pulp_last_updated, sock_connect_timeout, download_concurrency, total_timeout, name, client_cert, connect_timeout, headers, proxy_url, max_retries, url, sock_read_timeout, pulp_created, metadata_only, git_ref].hash
377
377
  end
378
378
 
379
379
  # Builds the object from hash