pulp_maven_client 0.12.0 → 0.13.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (47) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +4 -4
  3. data/docs/ContentArtifactApi.md +6 -6
  4. data/docs/DistributionsMavenApi.md +4 -4
  5. data/docs/MavenMavenArtifact.md +2 -0
  6. data/docs/MavenMavenDistribution.md +2 -0
  7. data/docs/MavenMavenDistributionResponse.md +4 -0
  8. data/docs/MavenMavenRemote.md +6 -6
  9. data/docs/MavenMavenRemoteResponse.md +9 -9
  10. data/docs/MavenMavenRepository.md +2 -0
  11. data/docs/MavenMavenRepositoryResponse.md +2 -0
  12. data/docs/PatchedmavenMavenDistribution.md +2 -0
  13. data/docs/PatchedmavenMavenRemote.md +6 -6
  14. data/docs/PatchedmavenMavenRepository.md +2 -0
  15. data/docs/RepositoriesMavenApi.md +20 -4
  16. data/lib/pulp_maven_client/api/content_artifact_api.rb +6 -6
  17. data/lib/pulp_maven_client/api/distributions_maven_api.rb +4 -4
  18. data/lib/pulp_maven_client/api/repositories_maven_api.rb +29 -5
  19. data/lib/pulp_maven_client/models/maven_maven_artifact.rb +11 -1
  20. data/lib/pulp_maven_client/models/maven_maven_distribution.rb +12 -1
  21. data/lib/pulp_maven_client/models/maven_maven_distribution_response.rb +22 -1
  22. data/lib/pulp_maven_client/models/maven_maven_remote.rb +48 -33
  23. data/lib/pulp_maven_client/models/maven_maven_remote_response.rb +64 -49
  24. data/lib/pulp_maven_client/models/maven_maven_repository.rb +42 -1
  25. data/lib/pulp_maven_client/models/maven_maven_repository_response.rb +42 -1
  26. data/lib/pulp_maven_client/models/patchedmaven_maven_distribution.rb +12 -1
  27. data/lib/pulp_maven_client/models/patchedmaven_maven_remote.rb +48 -33
  28. data/lib/pulp_maven_client/models/patchedmaven_maven_repository.rb +42 -1
  29. data/lib/pulp_maven_client/models/set_label.rb +0 -11
  30. data/lib/pulp_maven_client/models/set_label_response.rb +0 -21
  31. data/lib/pulp_maven_client/models/unset_label.rb +0 -11
  32. data/lib/pulp_maven_client/models/unset_label_response.rb +0 -21
  33. data/lib/pulp_maven_client/version.rb +1 -1
  34. data/spec/api/content_artifact_api_spec.rb +3 -3
  35. data/spec/api/distributions_maven_api_spec.rb +2 -2
  36. data/spec/api/repositories_maven_api_spec.rb +10 -2
  37. data/spec/models/maven_maven_artifact_spec.rb +6 -0
  38. data/spec/models/maven_maven_distribution_response_spec.rb +12 -0
  39. data/spec/models/maven_maven_distribution_spec.rb +6 -0
  40. data/spec/models/maven_maven_remote_response_spec.rb +10 -10
  41. data/spec/models/maven_maven_remote_spec.rb +17 -17
  42. data/spec/models/maven_maven_repository_response_spec.rb +6 -0
  43. data/spec/models/maven_maven_repository_spec.rb +6 -0
  44. data/spec/models/patchedmaven_maven_distribution_spec.rb +6 -0
  45. data/spec/models/patchedmaven_maven_remote_spec.rb +17 -17
  46. data/spec/models/patchedmaven_maven_repository_spec.rb +6 -0
  47. metadata +24 -24
@@ -19,6 +19,9 @@ module PulpMavenClient
19
19
  # A URI of a repository the new content unit should be associated with.
20
20
  attr_accessor :repository
21
21
 
22
+ # When set to true, existing content in the repository with the same unique key will be silently overwritten. When set to false, the task will fail if content would be overwritten. Only used when 'repository' is specified. Defaults to true.
23
+ attr_accessor :overwrite
24
+
22
25
  # A dictionary of arbitrary key/value pairs used to describe a specific Content instance.
23
26
  attr_accessor :pulp_labels
24
27
 
@@ -32,6 +35,7 @@ module PulpMavenClient
32
35
  def self.attribute_map
33
36
  {
34
37
  :'repository' => :'repository',
38
+ :'overwrite' => :'overwrite',
35
39
  :'pulp_labels' => :'pulp_labels',
36
40
  :'artifact' => :'artifact',
37
41
  :'relative_path' => :'relative_path'
@@ -47,6 +51,7 @@ module PulpMavenClient
47
51
  def self.openapi_types
48
52
  {
49
53
  :'repository' => :'String',
54
+ :'overwrite' => :'Boolean',
50
55
  :'pulp_labels' => :'Hash<String, String>',
51
56
  :'artifact' => :'String',
52
57
  :'relative_path' => :'String'
@@ -78,6 +83,10 @@ module PulpMavenClient
78
83
  self.repository = attributes[:'repository']
79
84
  end
80
85
 
86
+ if attributes.key?(:'overwrite')
87
+ self.overwrite = attributes[:'overwrite']
88
+ end
89
+
81
90
  if attributes.key?(:'pulp_labels')
82
91
  if (value = attributes[:'pulp_labels']).is_a?(Hash)
83
92
  self.pulp_labels = value
@@ -147,6 +156,7 @@ module PulpMavenClient
147
156
  return true if self.equal?(o)
148
157
  self.class == o.class &&
149
158
  repository == o.repository &&
159
+ overwrite == o.overwrite &&
150
160
  pulp_labels == o.pulp_labels &&
151
161
  artifact == o.artifact &&
152
162
  relative_path == o.relative_path
@@ -161,7 +171,7 @@ module PulpMavenClient
161
171
  # Calculates hash code according to all attributes.
162
172
  # @return [Integer] Hash code
163
173
  def hash
164
- [repository, pulp_labels, artifact, relative_path].hash
174
+ [repository, overwrite, pulp_labels, artifact, relative_path].hash
165
175
  end
166
176
 
167
177
  # Builds the object from hash
@@ -33,6 +33,9 @@ module PulpMavenClient
33
33
  # The latest RepositoryVersion for this Repository will be served.
34
34
  attr_accessor :repository
35
35
 
36
+ # RepositoryVersion to be served
37
+ attr_accessor :repository_version
38
+
36
39
  # Remote that can be used to fetch content when using pull-through caching.
37
40
  attr_accessor :remote
38
41
 
@@ -45,6 +48,7 @@ module PulpMavenClient
45
48
  :'pulp_labels' => :'pulp_labels',
46
49
  :'name' => :'name',
47
50
  :'repository' => :'repository',
51
+ :'repository_version' => :'repository_version',
48
52
  :'remote' => :'remote'
49
53
  }
50
54
  end
@@ -63,6 +67,7 @@ module PulpMavenClient
63
67
  :'pulp_labels' => :'Hash<String, String>',
64
68
  :'name' => :'String',
65
69
  :'repository' => :'String',
70
+ :'repository_version' => :'String',
66
71
  :'remote' => :'String'
67
72
  }
68
73
  end
@@ -72,6 +77,7 @@ module PulpMavenClient
72
77
  Set.new([
73
78
  :'content_guard',
74
79
  :'repository',
80
+ :'repository_version',
75
81
  :'remote'
76
82
  ])
77
83
  end
@@ -123,6 +129,10 @@ module PulpMavenClient
123
129
  self.repository = attributes[:'repository']
124
130
  end
125
131
 
132
+ if attributes.key?(:'repository_version')
133
+ self.repository_version = attributes[:'repository_version']
134
+ end
135
+
126
136
  if attributes.key?(:'remote')
127
137
  self.remote = attributes[:'remote']
128
138
  end
@@ -202,6 +212,7 @@ module PulpMavenClient
202
212
  pulp_labels == o.pulp_labels &&
203
213
  name == o.name &&
204
214
  repository == o.repository &&
215
+ repository_version == o.repository_version &&
205
216
  remote == o.remote
206
217
  end
207
218
 
@@ -214,7 +225,7 @@ module PulpMavenClient
214
225
  # Calculates hash code according to all attributes.
215
226
  # @return [Integer] Hash code
216
227
  def hash
217
- [base_path, content_guard, hidden, pulp_labels, name, repository, remote].hash
228
+ [base_path, content_guard, hidden, pulp_labels, name, repository, repository_version, remote].hash
218
229
  end
219
230
 
220
231
  # Builds the object from hash
@@ -36,6 +36,9 @@ module PulpMavenClient
36
36
  # An optional content-guard.
37
37
  attr_accessor :content_guard
38
38
 
39
+ # The Pulp Resource Name (PRN) of the associated optional content guard.
40
+ attr_accessor :content_guard_prn
41
+
39
42
  # Timestamp since when the distributed content served by this distribution has not changed. If equals to `null`, no guarantee is provided about content changes.
40
43
  attr_accessor :no_content_change_since
41
44
 
@@ -50,6 +53,9 @@ module PulpMavenClient
50
53
  # The latest RepositoryVersion for this Repository will be served.
51
54
  attr_accessor :repository
52
55
 
56
+ # RepositoryVersion to be served
57
+ attr_accessor :repository_version
58
+
53
59
  # Remote that can be used to fetch content when using pull-through caching.
54
60
  attr_accessor :remote
55
61
 
@@ -63,11 +69,13 @@ module PulpMavenClient
63
69
  :'base_path' => :'base_path',
64
70
  :'base_url' => :'base_url',
65
71
  :'content_guard' => :'content_guard',
72
+ :'content_guard_prn' => :'content_guard_prn',
66
73
  :'no_content_change_since' => :'no_content_change_since',
67
74
  :'hidden' => :'hidden',
68
75
  :'pulp_labels' => :'pulp_labels',
69
76
  :'name' => :'name',
70
77
  :'repository' => :'repository',
78
+ :'repository_version' => :'repository_version',
71
79
  :'remote' => :'remote'
72
80
  }
73
81
  end
@@ -87,11 +95,13 @@ module PulpMavenClient
87
95
  :'base_path' => :'String',
88
96
  :'base_url' => :'String',
89
97
  :'content_guard' => :'String',
98
+ :'content_guard_prn' => :'String',
90
99
  :'no_content_change_since' => :'String',
91
100
  :'hidden' => :'Boolean',
92
101
  :'pulp_labels' => :'Hash<String, String>',
93
102
  :'name' => :'String',
94
103
  :'repository' => :'String',
104
+ :'repository_version' => :'String',
95
105
  :'remote' => :'String'
96
106
  }
97
107
  end
@@ -101,6 +111,7 @@ module PulpMavenClient
101
111
  Set.new([
102
112
  :'content_guard',
103
113
  :'repository',
114
+ :'repository_version',
104
115
  :'remote'
105
116
  ])
106
117
  end
@@ -150,6 +161,10 @@ module PulpMavenClient
150
161
  self.content_guard = attributes[:'content_guard']
151
162
  end
152
163
 
164
+ if attributes.key?(:'content_guard_prn')
165
+ self.content_guard_prn = attributes[:'content_guard_prn']
166
+ end
167
+
153
168
  if attributes.key?(:'no_content_change_since')
154
169
  self.no_content_change_since = attributes[:'no_content_change_since']
155
170
  end
@@ -176,6 +191,10 @@ module PulpMavenClient
176
191
  self.repository = attributes[:'repository']
177
192
  end
178
193
 
194
+ if attributes.key?(:'repository_version')
195
+ self.repository_version = attributes[:'repository_version']
196
+ end
197
+
179
198
  if attributes.key?(:'remote')
180
199
  self.remote = attributes[:'remote']
181
200
  end
@@ -218,11 +237,13 @@ module PulpMavenClient
218
237
  base_path == o.base_path &&
219
238
  base_url == o.base_url &&
220
239
  content_guard == o.content_guard &&
240
+ content_guard_prn == o.content_guard_prn &&
221
241
  no_content_change_since == o.no_content_change_since &&
222
242
  hidden == o.hidden &&
223
243
  pulp_labels == o.pulp_labels &&
224
244
  name == o.name &&
225
245
  repository == o.repository &&
246
+ repository_version == o.repository_version &&
226
247
  remote == o.remote
227
248
  end
228
249
 
@@ -235,7 +256,7 @@ module PulpMavenClient
235
256
  # Calculates hash code according to all attributes.
236
257
  # @return [Integer] Hash code
237
258
  def hash
238
- [pulp_href, prn, pulp_created, pulp_last_updated, base_path, base_url, content_guard, no_content_change_since, hidden, pulp_labels, name, repository, remote].hash
259
+ [pulp_href, prn, pulp_created, pulp_last_updated, base_path, base_url, content_guard, content_guard_prn, no_content_change_since, hidden, pulp_labels, name, repository, repository_version, remote].hash
239
260
  end
240
261
 
241
262
  # Builds the object from hash
@@ -22,6 +22,11 @@ module PulpMavenClient
22
22
  # The URL of an external content source.
23
23
  attr_accessor :url
24
24
 
25
+ attr_accessor :pulp_labels
26
+
27
+ # The policy to use when downloading content. * `immediate` - When syncing, download all metadata and content now.
28
+ attr_accessor :policy
29
+
25
30
  # A PEM encoded CA certificate used to validate the server certificate presented by the remote server.
26
31
  attr_accessor :ca_cert
27
32
 
@@ -49,17 +54,9 @@ module PulpMavenClient
49
54
  # The password to be used for authentication when syncing. Extra leading and trailing whitespace characters are not trimmed.
50
55
  attr_accessor :password
51
56
 
52
- attr_accessor :pulp_labels
53
-
54
- # Total number of simultaneous connections. If not set then the default value will be used.
55
- attr_accessor :download_concurrency
56
-
57
57
  # Maximum number of retry attempts after a download failure. If not set then the default value (3) will be used.
58
58
  attr_accessor :max_retries
59
59
 
60
- # The policy to use when downloading content. * `immediate` - When syncing, download all metadata and content now.
61
- attr_accessor :policy
62
-
63
60
  # aiohttp.ClientTimeout.total (q.v.) for download-connections. The default is null, which will cause the default from the aiohttp library to be used.
64
61
  attr_accessor :total_timeout
65
62
 
@@ -75,6 +72,9 @@ module PulpMavenClient
75
72
  # Headers for aiohttp.Clientsession
76
73
  attr_accessor :headers
77
74
 
75
+ # Total number of simultaneous connections. If not set then the default value will be used.
76
+ attr_accessor :download_concurrency
77
+
78
78
  # Limits requests per second for each concurrent downloader
79
79
  attr_accessor :rate_limit
80
80
 
@@ -105,6 +105,8 @@ module PulpMavenClient
105
105
  {
106
106
  :'name' => :'name',
107
107
  :'url' => :'url',
108
+ :'pulp_labels' => :'pulp_labels',
109
+ :'policy' => :'policy',
108
110
  :'ca_cert' => :'ca_cert',
109
111
  :'client_cert' => :'client_cert',
110
112
  :'client_key' => :'client_key',
@@ -114,15 +116,13 @@ module PulpMavenClient
114
116
  :'proxy_password' => :'proxy_password',
115
117
  :'username' => :'username',
116
118
  :'password' => :'password',
117
- :'pulp_labels' => :'pulp_labels',
118
- :'download_concurrency' => :'download_concurrency',
119
119
  :'max_retries' => :'max_retries',
120
- :'policy' => :'policy',
121
120
  :'total_timeout' => :'total_timeout',
122
121
  :'connect_timeout' => :'connect_timeout',
123
122
  :'sock_connect_timeout' => :'sock_connect_timeout',
124
123
  :'sock_read_timeout' => :'sock_read_timeout',
125
124
  :'headers' => :'headers',
125
+ :'download_concurrency' => :'download_concurrency',
126
126
  :'rate_limit' => :'rate_limit'
127
127
  }
128
128
  end
@@ -137,6 +137,8 @@ module PulpMavenClient
137
137
  {
138
138
  :'name' => :'String',
139
139
  :'url' => :'String',
140
+ :'pulp_labels' => :'Hash<String, String>',
141
+ :'policy' => :'PolicyEnum',
140
142
  :'ca_cert' => :'String',
141
143
  :'client_cert' => :'String',
142
144
  :'client_key' => :'String',
@@ -146,15 +148,13 @@ module PulpMavenClient
146
148
  :'proxy_password' => :'String',
147
149
  :'username' => :'String',
148
150
  :'password' => :'String',
149
- :'pulp_labels' => :'Hash<String, String>',
150
- :'download_concurrency' => :'Integer',
151
151
  :'max_retries' => :'Integer',
152
- :'policy' => :'PolicyEnum',
153
152
  :'total_timeout' => :'Float',
154
153
  :'connect_timeout' => :'Float',
155
154
  :'sock_connect_timeout' => :'Float',
156
155
  :'sock_read_timeout' => :'Float',
157
156
  :'headers' => :'Array<Object>',
157
+ :'download_concurrency' => :'Integer',
158
158
  :'rate_limit' => :'Integer'
159
159
  }
160
160
  end
@@ -170,12 +170,12 @@ module PulpMavenClient
170
170
  :'proxy_password',
171
171
  :'username',
172
172
  :'password',
173
- :'download_concurrency',
174
173
  :'max_retries',
175
174
  :'total_timeout',
176
175
  :'connect_timeout',
177
176
  :'sock_connect_timeout',
178
177
  :'sock_read_timeout',
178
+ :'download_concurrency',
179
179
  :'rate_limit'
180
180
  ])
181
181
  end
@@ -207,6 +207,16 @@ module PulpMavenClient
207
207
  self.url = nil
208
208
  end
209
209
 
210
+ if attributes.key?(:'pulp_labels')
211
+ if (value = attributes[:'pulp_labels']).is_a?(Hash)
212
+ self.pulp_labels = value
213
+ end
214
+ end
215
+
216
+ if attributes.key?(:'policy')
217
+ self.policy = attributes[:'policy']
218
+ end
219
+
210
220
  if attributes.key?(:'ca_cert')
211
221
  self.ca_cert = attributes[:'ca_cert']
212
222
  end
@@ -243,24 +253,10 @@ module PulpMavenClient
243
253
  self.password = attributes[:'password']
244
254
  end
245
255
 
246
- if attributes.key?(:'pulp_labels')
247
- if (value = attributes[:'pulp_labels']).is_a?(Hash)
248
- self.pulp_labels = value
249
- end
250
- end
251
-
252
- if attributes.key?(:'download_concurrency')
253
- self.download_concurrency = attributes[:'download_concurrency']
254
- end
255
-
256
256
  if attributes.key?(:'max_retries')
257
257
  self.max_retries = attributes[:'max_retries']
258
258
  end
259
259
 
260
- if attributes.key?(:'policy')
261
- self.policy = attributes[:'policy']
262
- end
263
-
264
260
  if attributes.key?(:'total_timeout')
265
261
  self.total_timeout = attributes[:'total_timeout']
266
262
  end
@@ -283,6 +279,10 @@ module PulpMavenClient
283
279
  end
284
280
  end
285
281
 
282
+ if attributes.key?(:'download_concurrency')
283
+ self.download_concurrency = attributes[:'download_concurrency']
284
+ end
285
+
286
286
  if attributes.key?(:'rate_limit')
287
287
  self.rate_limit = attributes[:'rate_limit']
288
288
  end
@@ -357,6 +357,10 @@ module PulpMavenClient
357
357
  invalid_properties.push('invalid value for "sock_read_timeout", must be greater than or equal to 0.0.')
358
358
  end
359
359
 
360
+ if !@download_concurrency.nil? && @download_concurrency < 1
361
+ invalid_properties.push('invalid value for "download_concurrency", must be greater than or equal to 1.')
362
+ end
363
+
360
364
  invalid_properties
361
365
  end
362
366
 
@@ -380,6 +384,7 @@ module PulpMavenClient
380
384
  return false if !@connect_timeout.nil? && @connect_timeout < 0.0
381
385
  return false if !@sock_connect_timeout.nil? && @sock_connect_timeout < 0.0
382
386
  return false if !@sock_read_timeout.nil? && @sock_read_timeout < 0.0
387
+ return false if !@download_concurrency.nil? && @download_concurrency < 1
383
388
  true
384
389
  end
385
390
 
@@ -531,6 +536,16 @@ module PulpMavenClient
531
536
  @sock_read_timeout = sock_read_timeout
532
537
  end
533
538
 
539
+ # Custom attribute writer method with validation
540
+ # @param [Object] download_concurrency Value to be assigned
541
+ def download_concurrency=(download_concurrency)
542
+ if !download_concurrency.nil? && download_concurrency < 1
543
+ fail ArgumentError, 'invalid value for "download_concurrency", must be greater than or equal to 1.'
544
+ end
545
+
546
+ @download_concurrency = download_concurrency
547
+ end
548
+
534
549
  # Checks equality by comparing each attribute.
535
550
  # @param [Object] Object to be compared
536
551
  def ==(o)
@@ -538,6 +553,8 @@ module PulpMavenClient
538
553
  self.class == o.class &&
539
554
  name == o.name &&
540
555
  url == o.url &&
556
+ pulp_labels == o.pulp_labels &&
557
+ policy == o.policy &&
541
558
  ca_cert == o.ca_cert &&
542
559
  client_cert == o.client_cert &&
543
560
  client_key == o.client_key &&
@@ -547,15 +564,13 @@ module PulpMavenClient
547
564
  proxy_password == o.proxy_password &&
548
565
  username == o.username &&
549
566
  password == o.password &&
550
- pulp_labels == o.pulp_labels &&
551
- download_concurrency == o.download_concurrency &&
552
567
  max_retries == o.max_retries &&
553
- policy == o.policy &&
554
568
  total_timeout == o.total_timeout &&
555
569
  connect_timeout == o.connect_timeout &&
556
570
  sock_connect_timeout == o.sock_connect_timeout &&
557
571
  sock_read_timeout == o.sock_read_timeout &&
558
572
  headers == o.headers &&
573
+ download_concurrency == o.download_concurrency &&
559
574
  rate_limit == o.rate_limit
560
575
  end
561
576
 
@@ -568,7 +583,7 @@ module PulpMavenClient
568
583
  # Calculates hash code according to all attributes.
569
584
  # @return [Integer] Hash code
570
585
  def hash
571
- [name, url, ca_cert, client_cert, client_key, tls_validation, proxy_url, proxy_username, proxy_password, username, password, pulp_labels, download_concurrency, max_retries, policy, total_timeout, connect_timeout, sock_connect_timeout, sock_read_timeout, headers, rate_limit].hash
586
+ [name, url, pulp_labels, policy, ca_cert, client_cert, client_key, tls_validation, proxy_url, proxy_username, proxy_password, username, password, max_retries, total_timeout, connect_timeout, sock_connect_timeout, sock_read_timeout, headers, download_concurrency, rate_limit].hash
572
587
  end
573
588
 
574
589
  # Builds the object from hash
@@ -33,6 +33,14 @@ module PulpMavenClient
33
33
  # The URL of an external content source.
34
34
  attr_accessor :url
35
35
 
36
+ attr_accessor :pulp_labels
37
+
38
+ # The policy to use when downloading content. * `immediate` - When syncing, download all metadata and content now.
39
+ attr_accessor :policy
40
+
41
+ # List of hidden (write only) fields
42
+ attr_accessor :hidden_fields
43
+
36
44
  # A PEM encoded CA certificate used to validate the server certificate presented by the remote server.
37
45
  attr_accessor :ca_cert
38
46
 
@@ -45,17 +53,9 @@ module PulpMavenClient
45
53
  # The proxy URL. Format: scheme://host:port
46
54
  attr_accessor :proxy_url
47
55
 
48
- attr_accessor :pulp_labels
49
-
50
- # Total number of simultaneous connections. If not set then the default value will be used.
51
- attr_accessor :download_concurrency
52
-
53
56
  # Maximum number of retry attempts after a download failure. If not set then the default value (3) will be used.
54
57
  attr_accessor :max_retries
55
58
 
56
- # The policy to use when downloading content. * `immediate` - When syncing, download all metadata and content now.
57
- attr_accessor :policy
58
-
59
59
  # aiohttp.ClientTimeout.total (q.v.) for download-connections. The default is null, which will cause the default from the aiohttp library to be used.
60
60
  attr_accessor :total_timeout
61
61
 
@@ -71,12 +71,12 @@ module PulpMavenClient
71
71
  # Headers for aiohttp.Clientsession
72
72
  attr_accessor :headers
73
73
 
74
+ # Total number of simultaneous connections. If not set then the default value will be used.
75
+ attr_accessor :download_concurrency
76
+
74
77
  # Limits requests per second for each concurrent downloader
75
78
  attr_accessor :rate_limit
76
79
 
77
- # List of hidden (write only) fields
78
- attr_accessor :hidden_fields
79
-
80
80
  class EnumAttributeValidator
81
81
  attr_reader :datatype
82
82
  attr_reader :allowable_values
@@ -108,21 +108,21 @@ module PulpMavenClient
108
108
  :'pulp_last_updated' => :'pulp_last_updated',
109
109
  :'name' => :'name',
110
110
  :'url' => :'url',
111
+ :'pulp_labels' => :'pulp_labels',
112
+ :'policy' => :'policy',
113
+ :'hidden_fields' => :'hidden_fields',
111
114
  :'ca_cert' => :'ca_cert',
112
115
  :'client_cert' => :'client_cert',
113
116
  :'tls_validation' => :'tls_validation',
114
117
  :'proxy_url' => :'proxy_url',
115
- :'pulp_labels' => :'pulp_labels',
116
- :'download_concurrency' => :'download_concurrency',
117
118
  :'max_retries' => :'max_retries',
118
- :'policy' => :'policy',
119
119
  :'total_timeout' => :'total_timeout',
120
120
  :'connect_timeout' => :'connect_timeout',
121
121
  :'sock_connect_timeout' => :'sock_connect_timeout',
122
122
  :'sock_read_timeout' => :'sock_read_timeout',
123
123
  :'headers' => :'headers',
124
- :'rate_limit' => :'rate_limit',
125
- :'hidden_fields' => :'hidden_fields'
124
+ :'download_concurrency' => :'download_concurrency',
125
+ :'rate_limit' => :'rate_limit'
126
126
  }
127
127
  end
128
128
 
@@ -140,21 +140,21 @@ module PulpMavenClient
140
140
  :'pulp_last_updated' => :'Time',
141
141
  :'name' => :'String',
142
142
  :'url' => :'String',
143
+ :'pulp_labels' => :'Hash<String, String>',
144
+ :'policy' => :'PolicyEnum',
145
+ :'hidden_fields' => :'Array<MavenMavenRemoteResponseHiddenFieldsInner>',
143
146
  :'ca_cert' => :'String',
144
147
  :'client_cert' => :'String',
145
148
  :'tls_validation' => :'Boolean',
146
149
  :'proxy_url' => :'String',
147
- :'pulp_labels' => :'Hash<String, String>',
148
- :'download_concurrency' => :'Integer',
149
150
  :'max_retries' => :'Integer',
150
- :'policy' => :'PolicyEnum',
151
151
  :'total_timeout' => :'Float',
152
152
  :'connect_timeout' => :'Float',
153
153
  :'sock_connect_timeout' => :'Float',
154
154
  :'sock_read_timeout' => :'Float',
155
155
  :'headers' => :'Array<Object>',
156
- :'rate_limit' => :'Integer',
157
- :'hidden_fields' => :'Array<MavenMavenRemoteResponseHiddenFieldsInner>'
156
+ :'download_concurrency' => :'Integer',
157
+ :'rate_limit' => :'Integer'
158
158
  }
159
159
  end
160
160
 
@@ -164,13 +164,13 @@ module PulpMavenClient
164
164
  :'ca_cert',
165
165
  :'client_cert',
166
166
  :'proxy_url',
167
- :'download_concurrency',
168
167
  :'max_retries',
169
168
  :'total_timeout',
170
169
  :'connect_timeout',
171
170
  :'sock_connect_timeout',
172
171
  :'sock_read_timeout',
173
- :'rate_limit',
172
+ :'download_concurrency',
173
+ :'rate_limit'
174
174
  ])
175
175
  end
176
176
 
@@ -217,6 +217,22 @@ module PulpMavenClient
217
217
  self.url = nil
218
218
  end
219
219
 
220
+ if attributes.key?(:'pulp_labels')
221
+ if (value = attributes[:'pulp_labels']).is_a?(Hash)
222
+ self.pulp_labels = value
223
+ end
224
+ end
225
+
226
+ if attributes.key?(:'policy')
227
+ self.policy = attributes[:'policy']
228
+ end
229
+
230
+ if attributes.key?(:'hidden_fields')
231
+ if (value = attributes[:'hidden_fields']).is_a?(Array)
232
+ self.hidden_fields = value
233
+ end
234
+ end
235
+
220
236
  if attributes.key?(:'ca_cert')
221
237
  self.ca_cert = attributes[:'ca_cert']
222
238
  end
@@ -233,24 +249,10 @@ module PulpMavenClient
233
249
  self.proxy_url = attributes[:'proxy_url']
234
250
  end
235
251
 
236
- if attributes.key?(:'pulp_labels')
237
- if (value = attributes[:'pulp_labels']).is_a?(Hash)
238
- self.pulp_labels = value
239
- end
240
- end
241
-
242
- if attributes.key?(:'download_concurrency')
243
- self.download_concurrency = attributes[:'download_concurrency']
244
- end
245
-
246
252
  if attributes.key?(:'max_retries')
247
253
  self.max_retries = attributes[:'max_retries']
248
254
  end
249
255
 
250
- if attributes.key?(:'policy')
251
- self.policy = attributes[:'policy']
252
- end
253
-
254
256
  if attributes.key?(:'total_timeout')
255
257
  self.total_timeout = attributes[:'total_timeout']
256
258
  end
@@ -273,14 +275,12 @@ module PulpMavenClient
273
275
  end
274
276
  end
275
277
 
276
- if attributes.key?(:'rate_limit')
277
- self.rate_limit = attributes[:'rate_limit']
278
+ if attributes.key?(:'download_concurrency')
279
+ self.download_concurrency = attributes[:'download_concurrency']
278
280
  end
279
281
 
280
- if attributes.key?(:'hidden_fields')
281
- if (value = attributes[:'hidden_fields']).is_a?(Array)
282
- self.hidden_fields = value
283
- end
282
+ if attributes.key?(:'rate_limit')
283
+ self.rate_limit = attributes[:'rate_limit']
284
284
  end
285
285
  end
286
286
 
@@ -313,6 +313,10 @@ module PulpMavenClient
313
313
  invalid_properties.push('invalid value for "sock_read_timeout", must be greater than or equal to 0.0.')
314
314
  end
315
315
 
316
+ if !@download_concurrency.nil? && @download_concurrency < 1
317
+ invalid_properties.push('invalid value for "download_concurrency", must be greater than or equal to 1.')
318
+ end
319
+
316
320
  invalid_properties
317
321
  end
318
322
 
@@ -326,6 +330,7 @@ module PulpMavenClient
326
330
  return false if !@connect_timeout.nil? && @connect_timeout < 0.0
327
331
  return false if !@sock_connect_timeout.nil? && @sock_connect_timeout < 0.0
328
332
  return false if !@sock_read_timeout.nil? && @sock_read_timeout < 0.0
333
+ return false if !@download_concurrency.nil? && @download_concurrency < 1
329
334
  true
330
335
  end
331
336
 
@@ -369,6 +374,16 @@ module PulpMavenClient
369
374
  @sock_read_timeout = sock_read_timeout
370
375
  end
371
376
 
377
+ # Custom attribute writer method with validation
378
+ # @param [Object] download_concurrency Value to be assigned
379
+ def download_concurrency=(download_concurrency)
380
+ if !download_concurrency.nil? && download_concurrency < 1
381
+ fail ArgumentError, 'invalid value for "download_concurrency", must be greater than or equal to 1.'
382
+ end
383
+
384
+ @download_concurrency = download_concurrency
385
+ end
386
+
372
387
  # Checks equality by comparing each attribute.
373
388
  # @param [Object] Object to be compared
374
389
  def ==(o)
@@ -380,21 +395,21 @@ module PulpMavenClient
380
395
  pulp_last_updated == o.pulp_last_updated &&
381
396
  name == o.name &&
382
397
  url == o.url &&
398
+ pulp_labels == o.pulp_labels &&
399
+ policy == o.policy &&
400
+ hidden_fields == o.hidden_fields &&
383
401
  ca_cert == o.ca_cert &&
384
402
  client_cert == o.client_cert &&
385
403
  tls_validation == o.tls_validation &&
386
404
  proxy_url == o.proxy_url &&
387
- pulp_labels == o.pulp_labels &&
388
- download_concurrency == o.download_concurrency &&
389
405
  max_retries == o.max_retries &&
390
- policy == o.policy &&
391
406
  total_timeout == o.total_timeout &&
392
407
  connect_timeout == o.connect_timeout &&
393
408
  sock_connect_timeout == o.sock_connect_timeout &&
394
409
  sock_read_timeout == o.sock_read_timeout &&
395
410
  headers == o.headers &&
396
- rate_limit == o.rate_limit &&
397
- hidden_fields == o.hidden_fields
411
+ download_concurrency == o.download_concurrency &&
412
+ rate_limit == o.rate_limit
398
413
  end
399
414
 
400
415
  # @see the `==` method
@@ -406,7 +421,7 @@ module PulpMavenClient
406
421
  # Calculates hash code according to all attributes.
407
422
  # @return [Integer] Hash code
408
423
  def hash
409
- [pulp_href, prn, pulp_created, pulp_last_updated, name, url, ca_cert, client_cert, tls_validation, proxy_url, pulp_labels, download_concurrency, max_retries, policy, total_timeout, connect_timeout, sock_connect_timeout, sock_read_timeout, headers, rate_limit, hidden_fields].hash
424
+ [pulp_href, prn, pulp_created, pulp_last_updated, name, url, pulp_labels, policy, hidden_fields, ca_cert, client_cert, tls_validation, proxy_url, max_retries, total_timeout, connect_timeout, sock_connect_timeout, sock_read_timeout, headers, download_concurrency, rate_limit].hash
410
425
  end
411
426
 
412
427
  # Builds the object from hash