pulp_deb_client 2.0.0b2 → 2.0.0b3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +32 -18
- data/docs/ContentGenericContentsApi.md +12 -4
- data/docs/ContentInstallerFileIndexApi.md +20 -8
- data/docs/ContentInstallerPackagesApi.md +42 -4
- data/docs/ContentPackageIndexApi.md +20 -8
- data/docs/ContentPackagesApi.md +46 -6
- data/docs/{ContentReleasesApi.md → ContentReleaseFilesApi.md} +44 -32
- data/docs/ContentSummary.md +21 -0
- data/docs/{InstallerPackage.md → DebBasePackage.md} +40 -46
- data/docs/{DebDistribution.md → DebDebDistribution.md} +6 -6
- data/docs/{DebPublication.md → DebDebPublication.md} +5 -7
- data/docs/{DebRemote.md → DebDebRemote.md} +15 -21
- data/docs/DebDebRepository.md +27 -0
- data/docs/{GenericContent.md → DebGenericContent.md} +11 -17
- data/docs/{InstallerFileIndex.md → DebInstallerFileIndex.md} +5 -7
- data/docs/{PackageIndex.md → DebPackageIndex.md} +5 -7
- data/docs/{Release.md → DebReleaseFile.md} +5 -7
- data/docs/{VerbatimPublication.md → DebVerbatimPublication.md} +5 -7
- data/docs/DistributionsAptApi.md +16 -12
- data/docs/InlineResponse200.md +1 -1
- data/docs/InlineResponse2001.md +1 -1
- data/docs/InlineResponse20010.md +23 -0
- data/docs/InlineResponse2002.md +1 -1
- data/docs/InlineResponse2003.md +1 -1
- data/docs/InlineResponse2004.md +1 -1
- data/docs/InlineResponse2005.md +1 -1
- data/docs/InlineResponse2006.md +1 -1
- data/docs/InlineResponse2007.md +1 -1
- data/docs/InlineResponse2008.md +1 -1
- data/docs/InlineResponse2009.md +1 -1
- data/docs/PublicationsAptApi.md +12 -8
- data/docs/PublicationsVerbatimApi.md +12 -8
- data/docs/RemotesAptApi.md +30 -81
- data/docs/RepositoriesAptApi.md +465 -0
- data/docs/RepositoriesDebVersionsApi.md +214 -0
- data/docs/RepositoryAddRemoveContent.md +21 -0
- data/docs/RepositorySyncURL.md +2 -2
- data/docs/RepositoryVersion.md +25 -0
- data/lib/pulp_deb_client/api/content_generic_contents_api.rb +16 -4
- data/lib/pulp_deb_client/api/content_installer_file_index_api.rb +27 -9
- data/lib/pulp_deb_client/api/content_installer_packages_api.rb +61 -4
- data/lib/pulp_deb_client/api/content_package_index_api.rb +27 -9
- data/lib/pulp_deb_client/api/content_packages_api.rb +67 -7
- data/lib/pulp_deb_client/api/{content_releases_api.rb → content_release_files_api.rb} +61 -43
- data/lib/pulp_deb_client/api/distributions_apt_api.rb +19 -13
- data/lib/pulp_deb_client/api/publications_apt_api.rb +15 -9
- data/lib/pulp_deb_client/api/publications_verbatim_api.rb +15 -9
- data/lib/pulp_deb_client/api/remotes_apt_api.rb +40 -102
- data/lib/pulp_deb_client/api/repositories_apt_api.rb +568 -0
- data/lib/pulp_deb_client/api/repositories_deb_versions_api.rb +268 -0
- data/lib/pulp_deb_client/api_client.rb +1 -1
- data/lib/pulp_deb_client/api_error.rb +1 -1
- data/lib/pulp_deb_client/configuration.rb +1 -1
- data/lib/pulp_deb_client/models/async_operation_response.rb +12 -2
- data/lib/pulp_deb_client/models/content_summary.rb +246 -0
- data/lib/pulp_deb_client/models/{package.rb → deb_base_package.rb} +28 -62
- data/lib/pulp_deb_client/models/{deb_distribution.rb → deb_deb_distribution.rb} +30 -36
- data/lib/pulp_deb_client/models/{deb_publication.rb → deb_deb_publication.rb} +29 -42
- data/lib/pulp_deb_client/models/{deb_remote.rb → deb_deb_remote.rb} +87 -147
- data/lib/pulp_deb_client/models/deb_deb_repository.rb +294 -0
- data/lib/pulp_deb_client/models/{generic_content.rb → deb_generic_content.rb} +28 -62
- data/lib/pulp_deb_client/models/{installer_file_index.rb → deb_installer_file_index.rb} +28 -42
- data/lib/pulp_deb_client/models/{package_index.rb → deb_package_index.rb} +28 -42
- data/lib/pulp_deb_client/models/{release.rb → deb_release_file.rb} +28 -42
- data/lib/pulp_deb_client/models/{verbatim_publication.rb → deb_verbatim_publication.rb} +29 -42
- data/lib/pulp_deb_client/models/inline_response200.rb +15 -3
- data/lib/pulp_deb_client/models/inline_response2001.rb +15 -3
- data/lib/pulp_deb_client/models/inline_response20010.rb +247 -0
- data/lib/pulp_deb_client/models/inline_response2002.rb +15 -3
- data/lib/pulp_deb_client/models/inline_response2003.rb +15 -3
- data/lib/pulp_deb_client/models/inline_response2004.rb +15 -3
- data/lib/pulp_deb_client/models/inline_response2005.rb +15 -3
- data/lib/pulp_deb_client/models/inline_response2006.rb +15 -3
- data/lib/pulp_deb_client/models/inline_response2007.rb +15 -3
- data/lib/pulp_deb_client/models/inline_response2008.rb +15 -3
- data/lib/pulp_deb_client/models/inline_response2009.rb +15 -3
- data/lib/pulp_deb_client/models/repository_add_remove_content.rb +231 -0
- data/lib/pulp_deb_client/models/repository_sync_url.rb +22 -12
- data/lib/pulp_deb_client/models/repository_version.rb +244 -0
- data/lib/pulp_deb_client/version.rb +2 -2
- data/lib/pulp_deb_client.rb +18 -12
- data/pulp_deb_client.gemspec +1 -1
- data/spec/api/content_generic_contents_api_spec.rb +6 -2
- data/spec/api/content_installer_file_index_api_spec.rb +9 -3
- data/spec/api/content_installer_packages_api_spec.rb +21 -2
- data/spec/api/content_package_index_api_spec.rb +9 -3
- data/spec/api/content_packages_api_spec.rb +23 -3
- data/spec/api/{content_releases_api_spec.rb → content_release_files_api_spec.rb} +23 -17
- data/spec/api/distributions_apt_api_spec.rb +5 -3
- data/spec/api/publications_apt_api_spec.rb +5 -3
- data/spec/api/publications_verbatim_api_spec.rb +5 -3
- data/spec/api/remotes_apt_api_spec.rb +12 -22
- data/spec/api/repositories_apt_api_spec.rb +141 -0
- data/spec/api/repositories_deb_versions_api_spec.rb +91 -0
- data/spec/api_client_spec.rb +2 -2
- data/spec/configuration_spec.rb +1 -1
- data/spec/models/async_operation_response_spec.rb +1 -1
- data/spec/models/content_summary_spec.rb +53 -0
- data/spec/models/{package_spec.rb → deb_base_package_spec.rb} +9 -27
- data/spec/models/{deb_distribution_spec.rb → deb_deb_distribution_spec.rb} +9 -9
- data/spec/models/{deb_publication_spec.rb → deb_deb_publication_spec.rb} +9 -15
- data/spec/models/{deb_remote_spec.rb → deb_deb_remote_spec.rb} +14 -32
- data/spec/models/{verbatim_publication_spec.rb → deb_deb_repository_spec.rb} +13 -13
- data/spec/models/{generic_content_spec.rb → deb_generic_content_spec.rb} +9 -27
- data/spec/models/{package_index_spec.rb → deb_installer_file_index_spec.rb} +9 -15
- data/spec/models/{installer_file_index_spec.rb → deb_package_index_spec.rb} +9 -15
- data/spec/models/{release_spec.rb → deb_release_file_spec.rb} +9 -15
- data/spec/models/deb_verbatim_publication_spec.rb +65 -0
- data/spec/models/inline_response20010_spec.rb +59 -0
- data/spec/models/inline_response2001_spec.rb +1 -1
- data/spec/models/inline_response2002_spec.rb +1 -1
- data/spec/models/inline_response2003_spec.rb +1 -1
- data/spec/models/inline_response2004_spec.rb +1 -1
- data/spec/models/inline_response2005_spec.rb +1 -1
- data/spec/models/inline_response2006_spec.rb +1 -1
- data/spec/models/inline_response2007_spec.rb +1 -1
- data/spec/models/inline_response2008_spec.rb +1 -1
- data/spec/models/inline_response2009_spec.rb +1 -1
- data/spec/models/inline_response200_spec.rb +1 -1
- data/spec/models/repository_add_remove_content_spec.rb +53 -0
- data/spec/models/repository_sync_url_spec.rb +2 -2
- data/spec/models/repository_version_spec.rb +65 -0
- data/spec/spec_helper.rb +1 -1
- metadata +70 -46
- data/docs/Package.md +0 -99
- data/lib/pulp_deb_client/models/installer_package.rb +0 -1101
- data/spec/models/installer_package_spec.rb +0 -287
@@ -6,20 +6,18 @@
|
|
6
6
|
The version of the OpenAPI document: v3
|
7
7
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
|
-
OpenAPI Generator version: 4.1
|
9
|
+
OpenAPI Generator version: 4.2.1-SNAPSHOT
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
13
13
|
require 'date'
|
14
14
|
|
15
15
|
module PulpDebClient
|
16
|
-
class
|
17
|
-
attr_accessor :
|
16
|
+
class DebBasePackage
|
17
|
+
attr_accessor :pulp_href
|
18
18
|
|
19
19
|
# Timestamp of creation.
|
20
|
-
attr_accessor :
|
21
|
-
|
22
|
-
attr_accessor :_type
|
20
|
+
attr_accessor :pulp_created
|
23
21
|
|
24
22
|
# Artifact file representing the physical content
|
25
23
|
attr_accessor :artifact
|
@@ -27,12 +25,6 @@ module PulpDebClient
|
|
27
25
|
# Path where the artifact is located relative to distributions base_path
|
28
26
|
attr_accessor :relative_path
|
29
27
|
|
30
|
-
# An uploaded file that should be turned into the artifact of the content unit.
|
31
|
-
attr_accessor :file
|
32
|
-
|
33
|
-
# A URI of a repository the new content unit should be associated with.
|
34
|
-
attr_accessor :repository
|
35
|
-
|
36
28
|
# The MD5 checksum if available.
|
37
29
|
attr_accessor :md5
|
38
30
|
|
@@ -112,13 +104,10 @@ module PulpDebClient
|
|
112
104
|
# Attribute mapping from ruby-style variable name to JSON key.
|
113
105
|
def self.attribute_map
|
114
106
|
{
|
115
|
-
:'
|
116
|
-
:'
|
117
|
-
:'_type' => :'_type',
|
107
|
+
:'pulp_href' => :'pulp_href',
|
108
|
+
:'pulp_created' => :'pulp_created',
|
118
109
|
:'artifact' => :'artifact',
|
119
110
|
:'relative_path' => :'relative_path',
|
120
|
-
:'file' => :'file',
|
121
|
-
:'repository' => :'repository',
|
122
111
|
:'md5' => :'md5',
|
123
112
|
:'sha1' => :'sha1',
|
124
113
|
:'sha224' => :'sha224',
|
@@ -160,13 +149,10 @@ module PulpDebClient
|
|
160
149
|
# Attribute type mapping.
|
161
150
|
def self.openapi_types
|
162
151
|
{
|
163
|
-
:'
|
164
|
-
:'
|
165
|
-
:'_type' => :'String',
|
152
|
+
:'pulp_href' => :'String',
|
153
|
+
:'pulp_created' => :'DateTime',
|
166
154
|
:'artifact' => :'String',
|
167
155
|
:'relative_path' => :'String',
|
168
|
-
:'file' => :'String',
|
169
|
-
:'repository' => :'String',
|
170
156
|
:'md5' => :'String',
|
171
157
|
:'sha1' => :'String',
|
172
158
|
:'sha224' => :'String',
|
@@ -205,31 +191,33 @@ module PulpDebClient
|
|
205
191
|
}
|
206
192
|
end
|
207
193
|
|
194
|
+
# List of attributes with nullable: true
|
195
|
+
def self.openapi_nullable
|
196
|
+
Set.new([
|
197
|
+
])
|
198
|
+
end
|
199
|
+
|
208
200
|
# Initializes the object
|
209
201
|
# @param [Hash] attributes Model attributes in the form of hash
|
210
202
|
def initialize(attributes = {})
|
211
203
|
if (!attributes.is_a?(Hash))
|
212
|
-
fail ArgumentError, "The input argument (attributes) must be a hash in `PulpDebClient::
|
204
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `PulpDebClient::DebBasePackage` initialize method"
|
213
205
|
end
|
214
206
|
|
215
207
|
# check to see if the attribute exists and convert string to symbol for hash key
|
216
208
|
attributes = attributes.each_with_object({}) { |(k, v), h|
|
217
209
|
if (!self.class.attribute_map.key?(k.to_sym))
|
218
|
-
fail ArgumentError, "`#{k}` is not a valid attribute in `PulpDebClient::
|
210
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `PulpDebClient::DebBasePackage`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
219
211
|
end
|
220
212
|
h[k.to_sym] = v
|
221
213
|
}
|
222
214
|
|
223
|
-
if attributes.key?(:'
|
224
|
-
self.
|
215
|
+
if attributes.key?(:'pulp_href')
|
216
|
+
self.pulp_href = attributes[:'pulp_href']
|
225
217
|
end
|
226
218
|
|
227
|
-
if attributes.key?(:'
|
228
|
-
self.
|
229
|
-
end
|
230
|
-
|
231
|
-
if attributes.key?(:'_type')
|
232
|
-
self._type = attributes[:'_type']
|
219
|
+
if attributes.key?(:'pulp_created')
|
220
|
+
self.pulp_created = attributes[:'pulp_created']
|
233
221
|
end
|
234
222
|
|
235
223
|
if attributes.key?(:'artifact')
|
@@ -240,14 +228,6 @@ module PulpDebClient
|
|
240
228
|
self.relative_path = attributes[:'relative_path']
|
241
229
|
end
|
242
230
|
|
243
|
-
if attributes.key?(:'file')
|
244
|
-
self.file = attributes[:'file']
|
245
|
-
end
|
246
|
-
|
247
|
-
if attributes.key?(:'repository')
|
248
|
-
self.repository = attributes[:'repository']
|
249
|
-
end
|
250
|
-
|
251
231
|
if attributes.key?(:'md5')
|
252
232
|
self.md5 = attributes[:'md5']
|
253
233
|
end
|
@@ -393,10 +373,6 @@ module PulpDebClient
|
|
393
373
|
# @return Array for valid properties with the reasons
|
394
374
|
def list_invalid_properties
|
395
375
|
invalid_properties = Array.new
|
396
|
-
if !@_type.nil? && @_type.to_s.length < 1
|
397
|
-
invalid_properties.push('invalid value for "_type", the character length must be great than or equal to 1.')
|
398
|
-
end
|
399
|
-
|
400
376
|
if !@relative_path.nil? && @relative_path.to_s.length < 1
|
401
377
|
invalid_properties.push('invalid value for "relative_path", the character length must be great than or equal to 1.')
|
402
378
|
end
|
@@ -539,7 +515,6 @@ module PulpDebClient
|
|
539
515
|
# Check to see if the all the properties in the model are valid
|
540
516
|
# @return true if the model is valid
|
541
517
|
def valid?
|
542
|
-
return false if !@_type.nil? && @_type.to_s.length < 1
|
543
518
|
return false if !@relative_path.nil? && @relative_path.to_s.length < 1
|
544
519
|
return false if !@md5.nil? && @md5.to_s.length < 1
|
545
520
|
return false if !@sha1.nil? && @sha1.to_s.length < 1
|
@@ -577,16 +552,6 @@ module PulpDebClient
|
|
577
552
|
true
|
578
553
|
end
|
579
554
|
|
580
|
-
# Custom attribute writer method with validation
|
581
|
-
# @param [Object] _type Value to be assigned
|
582
|
-
def _type=(_type)
|
583
|
-
if !_type.nil? && _type.to_s.length < 1
|
584
|
-
fail ArgumentError, 'invalid value for "_type", the character length must be great than or equal to 1.'
|
585
|
-
end
|
586
|
-
|
587
|
-
@_type = _type
|
588
|
-
end
|
589
|
-
|
590
555
|
# Custom attribute writer method with validation
|
591
556
|
# @param [Object] relative_path Value to be assigned
|
592
557
|
def relative_path=(relative_path)
|
@@ -932,13 +897,10 @@ module PulpDebClient
|
|
932
897
|
def ==(o)
|
933
898
|
return true if self.equal?(o)
|
934
899
|
self.class == o.class &&
|
935
|
-
|
936
|
-
|
937
|
-
_type == o._type &&
|
900
|
+
pulp_href == o.pulp_href &&
|
901
|
+
pulp_created == o.pulp_created &&
|
938
902
|
artifact == o.artifact &&
|
939
903
|
relative_path == o.relative_path &&
|
940
|
-
file == o.file &&
|
941
|
-
repository == o.repository &&
|
942
904
|
md5 == o.md5 &&
|
943
905
|
sha1 == o.sha1 &&
|
944
906
|
sha224 == o.sha224 &&
|
@@ -985,7 +947,7 @@ module PulpDebClient
|
|
985
947
|
# Calculates hash code according to all attributes.
|
986
948
|
# @return [Integer] Hash code
|
987
949
|
def hash
|
988
|
-
[
|
950
|
+
[pulp_href, pulp_created, artifact, relative_path, md5, sha1, sha224, sha256, sha384, sha512, package, source, version, architecture, section, priority, origin, tag, bugs, essential, build_essential, installed_size, maintainer, original_maintainer, description, description_md5, homepage, built_using, auto_built_package, multi_arch, breaks, conflicts, depends, recommends, suggests, enhances, pre_depends, provides, replaces].hash
|
989
951
|
end
|
990
952
|
|
991
953
|
# Builds the object from hash
|
@@ -1074,7 +1036,11 @@ module PulpDebClient
|
|
1074
1036
|
hash = {}
|
1075
1037
|
self.class.attribute_map.each_pair do |attr, param|
|
1076
1038
|
value = self.send(attr)
|
1077
|
-
|
1039
|
+
if value.nil?
|
1040
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
1041
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
1042
|
+
end
|
1043
|
+
|
1078
1044
|
hash[param] = _to_hash(value)
|
1079
1045
|
end
|
1080
1046
|
hash
|
@@ -6,18 +6,18 @@
|
|
6
6
|
The version of the OpenAPI document: v3
|
7
7
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
|
-
OpenAPI Generator version: 4.1
|
9
|
+
OpenAPI Generator version: 4.2.1-SNAPSHOT
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
13
13
|
require 'date'
|
14
14
|
|
15
15
|
module PulpDebClient
|
16
|
-
class
|
17
|
-
attr_accessor :
|
16
|
+
class DebDebDistribution
|
17
|
+
attr_accessor :pulp_href
|
18
18
|
|
19
19
|
# Timestamp of creation.
|
20
|
-
attr_accessor :
|
20
|
+
attr_accessor :pulp_created
|
21
21
|
|
22
22
|
# The base (relative) path component of the published url. Avoid paths that overlap with other distribution base paths (e.g. \"foo\" and \"foo/bar\")
|
23
23
|
attr_accessor :base_path
|
@@ -37,8 +37,8 @@ module PulpDebClient
|
|
37
37
|
# Attribute mapping from ruby-style variable name to JSON key.
|
38
38
|
def self.attribute_map
|
39
39
|
{
|
40
|
-
:'
|
41
|
-
:'
|
40
|
+
:'pulp_href' => :'pulp_href',
|
41
|
+
:'pulp_created' => :'pulp_created',
|
42
42
|
:'base_path' => :'base_path',
|
43
43
|
:'base_url' => :'base_url',
|
44
44
|
:'content_guard' => :'content_guard',
|
@@ -50,8 +50,8 @@ module PulpDebClient
|
|
50
50
|
# Attribute type mapping.
|
51
51
|
def self.openapi_types
|
52
52
|
{
|
53
|
-
:'
|
54
|
-
:'
|
53
|
+
:'pulp_href' => :'String',
|
54
|
+
:'pulp_created' => :'DateTime',
|
55
55
|
:'base_path' => :'String',
|
56
56
|
:'base_url' => :'String',
|
57
57
|
:'content_guard' => :'String',
|
@@ -60,27 +60,35 @@ module PulpDebClient
|
|
60
60
|
}
|
61
61
|
end
|
62
62
|
|
63
|
+
# List of attributes with nullable: true
|
64
|
+
def self.openapi_nullable
|
65
|
+
Set.new([
|
66
|
+
:'content_guard',
|
67
|
+
:'publication'
|
68
|
+
])
|
69
|
+
end
|
70
|
+
|
63
71
|
# Initializes the object
|
64
72
|
# @param [Hash] attributes Model attributes in the form of hash
|
65
73
|
def initialize(attributes = {})
|
66
74
|
if (!attributes.is_a?(Hash))
|
67
|
-
fail ArgumentError, "The input argument (attributes) must be a hash in `PulpDebClient::
|
75
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `PulpDebClient::DebDebDistribution` initialize method"
|
68
76
|
end
|
69
77
|
|
70
78
|
# check to see if the attribute exists and convert string to symbol for hash key
|
71
79
|
attributes = attributes.each_with_object({}) { |(k, v), h|
|
72
80
|
if (!self.class.attribute_map.key?(k.to_sym))
|
73
|
-
fail ArgumentError, "`#{k}` is not a valid attribute in `PulpDebClient::
|
81
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `PulpDebClient::DebDebDistribution`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
74
82
|
end
|
75
83
|
h[k.to_sym] = v
|
76
84
|
}
|
77
85
|
|
78
|
-
if attributes.key?(:'
|
79
|
-
self.
|
86
|
+
if attributes.key?(:'pulp_href')
|
87
|
+
self.pulp_href = attributes[:'pulp_href']
|
80
88
|
end
|
81
89
|
|
82
|
-
if attributes.key?(:'
|
83
|
-
self.
|
90
|
+
if attributes.key?(:'pulp_created')
|
91
|
+
self.pulp_created = attributes[:'pulp_created']
|
84
92
|
end
|
85
93
|
|
86
94
|
if attributes.key?(:'base_path')
|
@@ -112,10 +120,6 @@ module PulpDebClient
|
|
112
120
|
invalid_properties.push('invalid value for "base_path", base_path cannot be nil.')
|
113
121
|
end
|
114
122
|
|
115
|
-
if @base_path.to_s.length > 255
|
116
|
-
invalid_properties.push('invalid value for "base_path", the character length must be smaller than or equal to 255.')
|
117
|
-
end
|
118
|
-
|
119
123
|
if @base_path.to_s.length < 1
|
120
124
|
invalid_properties.push('invalid value for "base_path", the character length must be great than or equal to 1.')
|
121
125
|
end
|
@@ -128,10 +132,6 @@ module PulpDebClient
|
|
128
132
|
invalid_properties.push('invalid value for "name", name cannot be nil.')
|
129
133
|
end
|
130
134
|
|
131
|
-
if @name.to_s.length > 255
|
132
|
-
invalid_properties.push('invalid value for "name", the character length must be smaller than or equal to 255.')
|
133
|
-
end
|
134
|
-
|
135
135
|
if @name.to_s.length < 1
|
136
136
|
invalid_properties.push('invalid value for "name", the character length must be great than or equal to 1.')
|
137
137
|
end
|
@@ -143,11 +143,9 @@ module PulpDebClient
|
|
143
143
|
# @return true if the model is valid
|
144
144
|
def valid?
|
145
145
|
return false if @base_path.nil?
|
146
|
-
return false if @base_path.to_s.length > 255
|
147
146
|
return false if @base_path.to_s.length < 1
|
148
147
|
return false if !@base_url.nil? && @base_url.to_s.length < 1
|
149
148
|
return false if @name.nil?
|
150
|
-
return false if @name.to_s.length > 255
|
151
149
|
return false if @name.to_s.length < 1
|
152
150
|
true
|
153
151
|
end
|
@@ -159,10 +157,6 @@ module PulpDebClient
|
|
159
157
|
fail ArgumentError, 'base_path cannot be nil'
|
160
158
|
end
|
161
159
|
|
162
|
-
if base_path.to_s.length > 255
|
163
|
-
fail ArgumentError, 'invalid value for "base_path", the character length must be smaller than or equal to 255.'
|
164
|
-
end
|
165
|
-
|
166
160
|
if base_path.to_s.length < 1
|
167
161
|
fail ArgumentError, 'invalid value for "base_path", the character length must be great than or equal to 1.'
|
168
162
|
end
|
@@ -187,10 +181,6 @@ module PulpDebClient
|
|
187
181
|
fail ArgumentError, 'name cannot be nil'
|
188
182
|
end
|
189
183
|
|
190
|
-
if name.to_s.length > 255
|
191
|
-
fail ArgumentError, 'invalid value for "name", the character length must be smaller than or equal to 255.'
|
192
|
-
end
|
193
|
-
|
194
184
|
if name.to_s.length < 1
|
195
185
|
fail ArgumentError, 'invalid value for "name", the character length must be great than or equal to 1.'
|
196
186
|
end
|
@@ -203,8 +193,8 @@ module PulpDebClient
|
|
203
193
|
def ==(o)
|
204
194
|
return true if self.equal?(o)
|
205
195
|
self.class == o.class &&
|
206
|
-
|
207
|
-
|
196
|
+
pulp_href == o.pulp_href &&
|
197
|
+
pulp_created == o.pulp_created &&
|
208
198
|
base_path == o.base_path &&
|
209
199
|
base_url == o.base_url &&
|
210
200
|
content_guard == o.content_guard &&
|
@@ -221,7 +211,7 @@ module PulpDebClient
|
|
221
211
|
# Calculates hash code according to all attributes.
|
222
212
|
# @return [Integer] Hash code
|
223
213
|
def hash
|
224
|
-
[
|
214
|
+
[pulp_href, pulp_created, base_path, base_url, content_guard, name, publication].hash
|
225
215
|
end
|
226
216
|
|
227
217
|
# Builds the object from hash
|
@@ -310,7 +300,11 @@ module PulpDebClient
|
|
310
300
|
hash = {}
|
311
301
|
self.class.attribute_map.each_pair do |attr, param|
|
312
302
|
value = self.send(attr)
|
313
|
-
|
303
|
+
if value.nil?
|
304
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
305
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
306
|
+
end
|
307
|
+
|
314
308
|
hash[param] = _to_hash(value)
|
315
309
|
end
|
316
310
|
hash
|
@@ -6,20 +6,18 @@
|
|
6
6
|
The version of the OpenAPI document: v3
|
7
7
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
|
-
OpenAPI Generator version: 4.1
|
9
|
+
OpenAPI Generator version: 4.2.1-SNAPSHOT
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
13
13
|
require 'date'
|
14
14
|
|
15
15
|
module PulpDebClient
|
16
|
-
class
|
17
|
-
attr_accessor :
|
16
|
+
class DebDebPublication
|
17
|
+
attr_accessor :pulp_href
|
18
18
|
|
19
19
|
# Timestamp of creation.
|
20
|
-
attr_accessor :
|
21
|
-
|
22
|
-
attr_accessor :_type
|
20
|
+
attr_accessor :pulp_created
|
23
21
|
|
24
22
|
attr_accessor :publisher
|
25
23
|
|
@@ -37,9 +35,8 @@ module PulpDebClient
|
|
37
35
|
# Attribute mapping from ruby-style variable name to JSON key.
|
38
36
|
def self.attribute_map
|
39
37
|
{
|
40
|
-
:'
|
41
|
-
:'
|
42
|
-
:'_type' => :'_type',
|
38
|
+
:'pulp_href' => :'pulp_href',
|
39
|
+
:'pulp_created' => :'pulp_created',
|
43
40
|
:'publisher' => :'publisher',
|
44
41
|
:'repository_version' => :'repository_version',
|
45
42
|
:'repository' => :'repository',
|
@@ -51,9 +48,8 @@ module PulpDebClient
|
|
51
48
|
# Attribute type mapping.
|
52
49
|
def self.openapi_types
|
53
50
|
{
|
54
|
-
:'
|
55
|
-
:'
|
56
|
-
:'_type' => :'String',
|
51
|
+
:'pulp_href' => :'String',
|
52
|
+
:'pulp_created' => :'DateTime',
|
57
53
|
:'publisher' => :'String',
|
58
54
|
:'repository_version' => :'String',
|
59
55
|
:'repository' => :'String',
|
@@ -62,31 +58,34 @@ module PulpDebClient
|
|
62
58
|
}
|
63
59
|
end
|
64
60
|
|
61
|
+
# List of attributes with nullable: true
|
62
|
+
def self.openapi_nullable
|
63
|
+
Set.new([
|
64
|
+
:'publisher',
|
65
|
+
])
|
66
|
+
end
|
67
|
+
|
65
68
|
# Initializes the object
|
66
69
|
# @param [Hash] attributes Model attributes in the form of hash
|
67
70
|
def initialize(attributes = {})
|
68
71
|
if (!attributes.is_a?(Hash))
|
69
|
-
fail ArgumentError, "The input argument (attributes) must be a hash in `PulpDebClient::
|
72
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `PulpDebClient::DebDebPublication` initialize method"
|
70
73
|
end
|
71
74
|
|
72
75
|
# check to see if the attribute exists and convert string to symbol for hash key
|
73
76
|
attributes = attributes.each_with_object({}) { |(k, v), h|
|
74
77
|
if (!self.class.attribute_map.key?(k.to_sym))
|
75
|
-
fail ArgumentError, "`#{k}` is not a valid attribute in `PulpDebClient::
|
78
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `PulpDebClient::DebDebPublication`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
76
79
|
end
|
77
80
|
h[k.to_sym] = v
|
78
81
|
}
|
79
82
|
|
80
|
-
if attributes.key?(:'
|
81
|
-
self.
|
83
|
+
if attributes.key?(:'pulp_href')
|
84
|
+
self.pulp_href = attributes[:'pulp_href']
|
82
85
|
end
|
83
86
|
|
84
|
-
if attributes.key?(:'
|
85
|
-
self.
|
86
|
-
end
|
87
|
-
|
88
|
-
if attributes.key?(:'_type')
|
89
|
-
self._type = attributes[:'_type']
|
87
|
+
if attributes.key?(:'pulp_created')
|
88
|
+
self.pulp_created = attributes[:'pulp_created']
|
90
89
|
end
|
91
90
|
|
92
91
|
if attributes.key?(:'publisher')
|
@@ -118,38 +117,22 @@ module PulpDebClient
|
|
118
117
|
# @return Array for valid properties with the reasons
|
119
118
|
def list_invalid_properties
|
120
119
|
invalid_properties = Array.new
|
121
|
-
if !@_type.nil? && @_type.to_s.length < 1
|
122
|
-
invalid_properties.push('invalid value for "_type", the character length must be great than or equal to 1.')
|
123
|
-
end
|
124
|
-
|
125
120
|
invalid_properties
|
126
121
|
end
|
127
122
|
|
128
123
|
# Check to see if the all the properties in the model are valid
|
129
124
|
# @return true if the model is valid
|
130
125
|
def valid?
|
131
|
-
return false if !@_type.nil? && @_type.to_s.length < 1
|
132
126
|
true
|
133
127
|
end
|
134
128
|
|
135
|
-
# Custom attribute writer method with validation
|
136
|
-
# @param [Object] _type Value to be assigned
|
137
|
-
def _type=(_type)
|
138
|
-
if !_type.nil? && _type.to_s.length < 1
|
139
|
-
fail ArgumentError, 'invalid value for "_type", the character length must be great than or equal to 1.'
|
140
|
-
end
|
141
|
-
|
142
|
-
@_type = _type
|
143
|
-
end
|
144
|
-
|
145
129
|
# Checks equality by comparing each attribute.
|
146
130
|
# @param [Object] Object to be compared
|
147
131
|
def ==(o)
|
148
132
|
return true if self.equal?(o)
|
149
133
|
self.class == o.class &&
|
150
|
-
|
151
|
-
|
152
|
-
_type == o._type &&
|
134
|
+
pulp_href == o.pulp_href &&
|
135
|
+
pulp_created == o.pulp_created &&
|
153
136
|
publisher == o.publisher &&
|
154
137
|
repository_version == o.repository_version &&
|
155
138
|
repository == o.repository &&
|
@@ -166,7 +149,7 @@ module PulpDebClient
|
|
166
149
|
# Calculates hash code according to all attributes.
|
167
150
|
# @return [Integer] Hash code
|
168
151
|
def hash
|
169
|
-
[
|
152
|
+
[pulp_href, pulp_created, publisher, repository_version, repository, simple, structured].hash
|
170
153
|
end
|
171
154
|
|
172
155
|
# Builds the object from hash
|
@@ -255,7 +238,11 @@ module PulpDebClient
|
|
255
238
|
hash = {}
|
256
239
|
self.class.attribute_map.each_pair do |attr, param|
|
257
240
|
value = self.send(attr)
|
258
|
-
|
241
|
+
if value.nil?
|
242
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
243
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
244
|
+
end
|
245
|
+
|
259
246
|
hash[param] = _to_hash(value)
|
260
247
|
end
|
261
248
|
hash
|