pulpcore_client 3.14.19 → 3.15.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.
- checksums.yaml +4 -4
- data/README.md +38 -5
- data/docs/AccessPoliciesApi.md +1 -1
- data/docs/ArtifactsApi.md +1 -1
- data/docs/ContentApi.md +1 -1
- data/docs/ContentguardsApi.md +1 -1
- data/docs/ContentguardsRbacApi.md +473 -0
- data/docs/ExportersFilesystemApi.md +362 -0
- data/docs/ExportersFilesystemExportsApi.md +243 -0
- data/docs/ExportersPulpApi.md +1 -1
- data/docs/ExportersPulpExportsApi.md +1 -1
- data/docs/FilesystemExport.md +21 -0
- data/docs/FilesystemExportResponse.md +25 -0
- data/docs/FilesystemExporter.md +21 -0
- data/docs/FilesystemExporterResponse.md +25 -0
- data/docs/GroupsApi.md +1 -1
- data/docs/GroupsModelPermissionsApi.md +1 -1
- data/docs/GroupsObjectPermissionsApi.md +1 -1
- data/docs/GroupsUsersApi.md +1 -1
- data/docs/ImportersPulpApi.md +1 -1
- data/docs/ImportersPulpImportCheckApi.md +1 -1
- data/docs/ImportersPulpImportsApi.md +1 -1
- data/docs/MethodEnum.md +16 -0
- data/docs/OrphansApi.md +1 -1
- data/docs/OrphansCleanup.md +3 -1
- data/docs/OrphansCleanupApi.md +1 -1
- data/docs/PaginatedFilesystemExportResponseList.md +23 -0
- data/docs/PaginatedFilesystemExporterResponseList.md +23 -0
- data/docs/PaginatedRBACContentGuardResponseList.md +23 -0
- data/docs/PatchedFilesystemExporter.md +21 -0
- data/docs/PatchedRBACContentGuard.md +19 -0
- data/docs/PublicationsApi.md +1 -1
- data/docs/RBACContentGuard.md +19 -0
- data/docs/RBACContentGuardPermission.md +19 -0
- data/docs/RBACContentGuardResponse.md +27 -0
- data/docs/ReclaimSpace.md +19 -0
- data/docs/RepairApi.md +1 -1
- data/docs/RepositoriesApi.md +1 -1
- data/docs/RepositoriesReclaimSpaceApi.md +61 -0
- data/docs/RepositoryResponse.md +3 -3
- data/docs/RepositoryVersionsApi.md +1 -1
- data/docs/SigningServicesApi.md +1 -1
- data/docs/StatusApi.md +1 -1
- data/docs/TaskGroupsApi.md +1 -1
- data/docs/TasksApi.md +1 -1
- data/docs/UploadsApi.md +1 -1
- data/docs/UsersApi.md +1 -1
- data/docs/WorkersApi.md +1 -1
- data/git_push.sh +58 -0
- data/lib/pulpcore_client/api/contentguards_rbac_api.rb +580 -0
- data/lib/pulpcore_client/api/exporters_filesystem_api.rb +442 -0
- data/lib/pulpcore_client/api/exporters_filesystem_exports_api.rb +297 -0
- data/lib/pulpcore_client/api/repositories_reclaim_space_api.rb +84 -0
- data/lib/pulpcore_client/api_client.rb +5 -2
- data/lib/pulpcore_client/configuration.rb +2 -3
- data/lib/pulpcore_client/models/filesystem_export.rb +229 -0
- data/lib/pulpcore_client/models/filesystem_export_response.rb +250 -0
- data/lib/pulpcore_client/models/filesystem_exporter.rb +238 -0
- data/lib/pulpcore_client/models/filesystem_exporter_response.rb +257 -0
- data/lib/pulpcore_client/models/method_enum.rb +37 -0
- data/lib/pulpcore_client/models/orphans_cleanup.rb +17 -4
- data/lib/pulpcore_client/models/paginated_filesystem_export_response_list.rb +237 -0
- data/lib/pulpcore_client/models/paginated_filesystem_exporter_response_list.rb +237 -0
- data/lib/pulpcore_client/models/paginated_rbac_content_guard_response_list.rb +237 -0
- data/lib/pulpcore_client/models/patched_filesystem_exporter.rb +228 -0
- data/lib/pulpcore_client/models/patched_rbac_content_guard.rb +219 -0
- data/lib/pulpcore_client/models/rbac_content_guard.rb +224 -0
- data/lib/pulpcore_client/models/rbac_content_guard_permission.rb +219 -0
- data/lib/pulpcore_client/models/rbac_content_guard_response.rb +261 -0
- data/lib/pulpcore_client/models/reclaim_space.rb +227 -0
- data/lib/pulpcore_client/models/repository_response.rb +17 -16
- data/lib/pulpcore_client/version.rb +1 -1
- data/lib/pulpcore_client.rb +18 -0
- data/pulpcore_client.gemspec +3 -3
- data/spec/api/contentguards_rbac_api_spec.rb +146 -0
- data/spec/api/exporters_filesystem_api_spec.rb +120 -0
- data/spec/api/exporters_filesystem_exports_api_spec.rb +91 -0
- data/spec/api/repositories_reclaim_space_api_spec.rb +46 -0
- data/spec/configuration_spec.rb +3 -3
- data/spec/models/filesystem_export_response_spec.rb +65 -0
- data/spec/models/filesystem_export_spec.rb +53 -0
- data/spec/models/filesystem_exporter_response_spec.rb +65 -0
- data/spec/models/filesystem_exporter_spec.rb +53 -0
- data/spec/models/method_enum_spec.rb +35 -0
- data/spec/models/orphans_cleanup_spec.rb +6 -0
- data/spec/models/paginated_filesystem_export_response_list_spec.rb +59 -0
- data/spec/models/paginated_filesystem_exporter_response_list_spec.rb +59 -0
- data/spec/models/paginated_rbac_content_guard_response_list_spec.rb +59 -0
- data/spec/models/patched_filesystem_exporter_spec.rb +53 -0
- data/spec/models/patched_rbac_content_guard_spec.rb +47 -0
- data/spec/models/rbac_content_guard_permission_spec.rb +47 -0
- data/spec/models/rbac_content_guard_response_spec.rb +71 -0
- data/spec/models/rbac_content_guard_spec.rb +47 -0
- data/spec/models/reclaim_space_spec.rb +47 -0
- data/spec/models/repository_response_spec.rb +1 -1
- metadata +158 -91
|
@@ -0,0 +1,261 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Pulp 3 API
|
|
3
|
+
|
|
4
|
+
#Fetch, Upload, Organize, and Distribute Software Packages
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: v3
|
|
7
|
+
Contact: pulp-list@redhat.com
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
OpenAPI Generator version: 4.3.1
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'date'
|
|
14
|
+
|
|
15
|
+
module PulpcoreClient
|
|
16
|
+
# Base serializer for use with :class:`pulpcore.app.models.Model` This ensures that all Serializers provide values for the 'pulp_href` field. The class provides a default for the ``ref_name`` attribute in the ModelSerializers's ``Meta`` class. This ensures that the OpenAPI definitions of plugins are namespaced properly.
|
|
17
|
+
class RBACContentGuardResponse
|
|
18
|
+
attr_accessor :pulp_href
|
|
19
|
+
|
|
20
|
+
# Timestamp of creation.
|
|
21
|
+
attr_accessor :pulp_created
|
|
22
|
+
|
|
23
|
+
# The unique name.
|
|
24
|
+
attr_accessor :name
|
|
25
|
+
|
|
26
|
+
# An optional description.
|
|
27
|
+
attr_accessor :description
|
|
28
|
+
|
|
29
|
+
attr_accessor :users
|
|
30
|
+
|
|
31
|
+
attr_accessor :groups
|
|
32
|
+
|
|
33
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
34
|
+
def self.attribute_map
|
|
35
|
+
{
|
|
36
|
+
:'pulp_href' => :'pulp_href',
|
|
37
|
+
:'pulp_created' => :'pulp_created',
|
|
38
|
+
:'name' => :'name',
|
|
39
|
+
:'description' => :'description',
|
|
40
|
+
:'users' => :'users',
|
|
41
|
+
:'groups' => :'groups'
|
|
42
|
+
}
|
|
43
|
+
end
|
|
44
|
+
|
|
45
|
+
# Attribute type mapping.
|
|
46
|
+
def self.openapi_types
|
|
47
|
+
{
|
|
48
|
+
:'pulp_href' => :'String',
|
|
49
|
+
:'pulp_created' => :'DateTime',
|
|
50
|
+
:'name' => :'String',
|
|
51
|
+
:'description' => :'String',
|
|
52
|
+
:'users' => :'String',
|
|
53
|
+
:'groups' => :'String'
|
|
54
|
+
}
|
|
55
|
+
end
|
|
56
|
+
|
|
57
|
+
# List of attributes with nullable: true
|
|
58
|
+
def self.openapi_nullable
|
|
59
|
+
Set.new([
|
|
60
|
+
:'description',
|
|
61
|
+
])
|
|
62
|
+
end
|
|
63
|
+
|
|
64
|
+
# Initializes the object
|
|
65
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
66
|
+
def initialize(attributes = {})
|
|
67
|
+
if (!attributes.is_a?(Hash))
|
|
68
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `PulpcoreClient::RBACContentGuardResponse` initialize method"
|
|
69
|
+
end
|
|
70
|
+
|
|
71
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
72
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
73
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
|
74
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `PulpcoreClient::RBACContentGuardResponse`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
|
75
|
+
end
|
|
76
|
+
h[k.to_sym] = v
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
if attributes.key?(:'pulp_href')
|
|
80
|
+
self.pulp_href = attributes[:'pulp_href']
|
|
81
|
+
end
|
|
82
|
+
|
|
83
|
+
if attributes.key?(:'pulp_created')
|
|
84
|
+
self.pulp_created = attributes[:'pulp_created']
|
|
85
|
+
end
|
|
86
|
+
|
|
87
|
+
if attributes.key?(:'name')
|
|
88
|
+
self.name = attributes[:'name']
|
|
89
|
+
end
|
|
90
|
+
|
|
91
|
+
if attributes.key?(:'description')
|
|
92
|
+
self.description = attributes[:'description']
|
|
93
|
+
end
|
|
94
|
+
|
|
95
|
+
if attributes.key?(:'users')
|
|
96
|
+
self.users = attributes[:'users']
|
|
97
|
+
end
|
|
98
|
+
|
|
99
|
+
if attributes.key?(:'groups')
|
|
100
|
+
self.groups = attributes[:'groups']
|
|
101
|
+
end
|
|
102
|
+
end
|
|
103
|
+
|
|
104
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
|
105
|
+
# @return Array for valid properties with the reasons
|
|
106
|
+
def list_invalid_properties
|
|
107
|
+
invalid_properties = Array.new
|
|
108
|
+
if @name.nil?
|
|
109
|
+
invalid_properties.push('invalid value for "name", name cannot be nil.')
|
|
110
|
+
end
|
|
111
|
+
|
|
112
|
+
invalid_properties
|
|
113
|
+
end
|
|
114
|
+
|
|
115
|
+
# Check to see if the all the properties in the model are valid
|
|
116
|
+
# @return true if the model is valid
|
|
117
|
+
def valid?
|
|
118
|
+
return false if @name.nil?
|
|
119
|
+
true
|
|
120
|
+
end
|
|
121
|
+
|
|
122
|
+
# Checks equality by comparing each attribute.
|
|
123
|
+
# @param [Object] Object to be compared
|
|
124
|
+
def ==(o)
|
|
125
|
+
return true if self.equal?(o)
|
|
126
|
+
self.class == o.class &&
|
|
127
|
+
pulp_href == o.pulp_href &&
|
|
128
|
+
pulp_created == o.pulp_created &&
|
|
129
|
+
name == o.name &&
|
|
130
|
+
description == o.description &&
|
|
131
|
+
users == o.users &&
|
|
132
|
+
groups == o.groups
|
|
133
|
+
end
|
|
134
|
+
|
|
135
|
+
# @see the `==` method
|
|
136
|
+
# @param [Object] Object to be compared
|
|
137
|
+
def eql?(o)
|
|
138
|
+
self == o
|
|
139
|
+
end
|
|
140
|
+
|
|
141
|
+
# Calculates hash code according to all attributes.
|
|
142
|
+
# @return [Integer] Hash code
|
|
143
|
+
def hash
|
|
144
|
+
[pulp_href, pulp_created, name, description, users, groups].hash
|
|
145
|
+
end
|
|
146
|
+
|
|
147
|
+
# Builds the object from hash
|
|
148
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
149
|
+
# @return [Object] Returns the model itself
|
|
150
|
+
def self.build_from_hash(attributes)
|
|
151
|
+
new.build_from_hash(attributes)
|
|
152
|
+
end
|
|
153
|
+
|
|
154
|
+
# Builds the object from hash
|
|
155
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
156
|
+
# @return [Object] Returns the model itself
|
|
157
|
+
def build_from_hash(attributes)
|
|
158
|
+
return nil unless attributes.is_a?(Hash)
|
|
159
|
+
self.class.openapi_types.each_pair do |key, type|
|
|
160
|
+
if type =~ /\AArray<(.*)>/i
|
|
161
|
+
# check to ensure the input is an array given that the attribute
|
|
162
|
+
# is documented as an array but the input is not
|
|
163
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
|
164
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
|
165
|
+
end
|
|
166
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
|
167
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
|
168
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
|
169
|
+
end
|
|
170
|
+
|
|
171
|
+
self
|
|
172
|
+
end
|
|
173
|
+
|
|
174
|
+
# Deserializes the data based on type
|
|
175
|
+
# @param string type Data type
|
|
176
|
+
# @param string value Value to be deserialized
|
|
177
|
+
# @return [Object] Deserialized data
|
|
178
|
+
def _deserialize(type, value)
|
|
179
|
+
case type.to_sym
|
|
180
|
+
when :DateTime
|
|
181
|
+
DateTime.parse(value)
|
|
182
|
+
when :Date
|
|
183
|
+
Date.parse(value)
|
|
184
|
+
when :String
|
|
185
|
+
value.to_s
|
|
186
|
+
when :Integer
|
|
187
|
+
value.to_i
|
|
188
|
+
when :Float
|
|
189
|
+
value.to_f
|
|
190
|
+
when :Boolean
|
|
191
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
|
192
|
+
true
|
|
193
|
+
else
|
|
194
|
+
false
|
|
195
|
+
end
|
|
196
|
+
when :Object
|
|
197
|
+
# generic object (usually a Hash), return directly
|
|
198
|
+
value
|
|
199
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
|
200
|
+
inner_type = Regexp.last_match[:inner_type]
|
|
201
|
+
value.map { |v| _deserialize(inner_type, v) }
|
|
202
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
|
203
|
+
k_type = Regexp.last_match[:k_type]
|
|
204
|
+
v_type = Regexp.last_match[:v_type]
|
|
205
|
+
{}.tap do |hash|
|
|
206
|
+
value.each do |k, v|
|
|
207
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
|
208
|
+
end
|
|
209
|
+
end
|
|
210
|
+
else # model
|
|
211
|
+
PulpcoreClient.const_get(type).build_from_hash(value)
|
|
212
|
+
end
|
|
213
|
+
end
|
|
214
|
+
|
|
215
|
+
# Returns the string representation of the object
|
|
216
|
+
# @return [String] String presentation of the object
|
|
217
|
+
def to_s
|
|
218
|
+
to_hash.to_s
|
|
219
|
+
end
|
|
220
|
+
|
|
221
|
+
# to_body is an alias to to_hash (backward compatibility)
|
|
222
|
+
# @return [Hash] Returns the object in the form of hash
|
|
223
|
+
def to_body
|
|
224
|
+
to_hash
|
|
225
|
+
end
|
|
226
|
+
|
|
227
|
+
# Returns the object in the form of hash
|
|
228
|
+
# @return [Hash] Returns the object in the form of hash
|
|
229
|
+
def to_hash
|
|
230
|
+
hash = {}
|
|
231
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
232
|
+
value = self.send(attr)
|
|
233
|
+
if value.nil?
|
|
234
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
|
235
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
236
|
+
end
|
|
237
|
+
|
|
238
|
+
hash[param] = _to_hash(value)
|
|
239
|
+
end
|
|
240
|
+
hash
|
|
241
|
+
end
|
|
242
|
+
|
|
243
|
+
# Outputs non-array value in the form of hash
|
|
244
|
+
# For object, use to_hash. Otherwise, just return the value
|
|
245
|
+
# @param [Object] value Any valid value
|
|
246
|
+
# @return [Hash] Returns the value in the form of hash
|
|
247
|
+
def _to_hash(value)
|
|
248
|
+
if value.is_a?(Array)
|
|
249
|
+
value.compact.map { |v| _to_hash(v) }
|
|
250
|
+
elsif value.is_a?(Hash)
|
|
251
|
+
{}.tap do |hash|
|
|
252
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
|
253
|
+
end
|
|
254
|
+
elsif value.respond_to? :to_hash
|
|
255
|
+
value.to_hash
|
|
256
|
+
else
|
|
257
|
+
value
|
|
258
|
+
end
|
|
259
|
+
end
|
|
260
|
+
end
|
|
261
|
+
end
|
|
@@ -0,0 +1,227 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Pulp 3 API
|
|
3
|
+
|
|
4
|
+
#Fetch, Upload, Organize, and Distribute Software Packages
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: v3
|
|
7
|
+
Contact: pulp-list@redhat.com
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
OpenAPI Generator version: 4.3.1
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'date'
|
|
14
|
+
|
|
15
|
+
module PulpcoreClient
|
|
16
|
+
# Serializer for reclaim disk space operation.
|
|
17
|
+
class ReclaimSpace
|
|
18
|
+
# Will reclaim space for the specified list of repos.
|
|
19
|
+
attr_accessor :repo_hrefs
|
|
20
|
+
|
|
21
|
+
# Will exclude repo versions from space reclaim.
|
|
22
|
+
attr_accessor :repo_versions_keeplist
|
|
23
|
+
|
|
24
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
25
|
+
def self.attribute_map
|
|
26
|
+
{
|
|
27
|
+
:'repo_hrefs' => :'repo_hrefs',
|
|
28
|
+
:'repo_versions_keeplist' => :'repo_versions_keeplist'
|
|
29
|
+
}
|
|
30
|
+
end
|
|
31
|
+
|
|
32
|
+
# Attribute type mapping.
|
|
33
|
+
def self.openapi_types
|
|
34
|
+
{
|
|
35
|
+
:'repo_hrefs' => :'Array<AnyType>',
|
|
36
|
+
:'repo_versions_keeplist' => :'Array<String>'
|
|
37
|
+
}
|
|
38
|
+
end
|
|
39
|
+
|
|
40
|
+
# List of attributes with nullable: true
|
|
41
|
+
def self.openapi_nullable
|
|
42
|
+
Set.new([
|
|
43
|
+
])
|
|
44
|
+
end
|
|
45
|
+
|
|
46
|
+
# Initializes the object
|
|
47
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
48
|
+
def initialize(attributes = {})
|
|
49
|
+
if (!attributes.is_a?(Hash))
|
|
50
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `PulpcoreClient::ReclaimSpace` initialize method"
|
|
51
|
+
end
|
|
52
|
+
|
|
53
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
54
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
55
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
|
56
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `PulpcoreClient::ReclaimSpace`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
|
57
|
+
end
|
|
58
|
+
h[k.to_sym] = v
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
if attributes.key?(:'repo_hrefs')
|
|
62
|
+
if (value = attributes[:'repo_hrefs']).is_a?(Array)
|
|
63
|
+
self.repo_hrefs = value
|
|
64
|
+
end
|
|
65
|
+
end
|
|
66
|
+
|
|
67
|
+
if attributes.key?(:'repo_versions_keeplist')
|
|
68
|
+
if (value = attributes[:'repo_versions_keeplist']).is_a?(Array)
|
|
69
|
+
self.repo_versions_keeplist = value
|
|
70
|
+
end
|
|
71
|
+
end
|
|
72
|
+
end
|
|
73
|
+
|
|
74
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
|
75
|
+
# @return Array for valid properties with the reasons
|
|
76
|
+
def list_invalid_properties
|
|
77
|
+
invalid_properties = Array.new
|
|
78
|
+
if @repo_hrefs.nil?
|
|
79
|
+
invalid_properties.push('invalid value for "repo_hrefs", repo_hrefs cannot be nil.')
|
|
80
|
+
end
|
|
81
|
+
|
|
82
|
+
invalid_properties
|
|
83
|
+
end
|
|
84
|
+
|
|
85
|
+
# Check to see if the all the properties in the model are valid
|
|
86
|
+
# @return true if the model is valid
|
|
87
|
+
def valid?
|
|
88
|
+
return false if @repo_hrefs.nil?
|
|
89
|
+
true
|
|
90
|
+
end
|
|
91
|
+
|
|
92
|
+
# Checks equality by comparing each attribute.
|
|
93
|
+
# @param [Object] Object to be compared
|
|
94
|
+
def ==(o)
|
|
95
|
+
return true if self.equal?(o)
|
|
96
|
+
self.class == o.class &&
|
|
97
|
+
repo_hrefs == o.repo_hrefs &&
|
|
98
|
+
repo_versions_keeplist == o.repo_versions_keeplist
|
|
99
|
+
end
|
|
100
|
+
|
|
101
|
+
# @see the `==` method
|
|
102
|
+
# @param [Object] Object to be compared
|
|
103
|
+
def eql?(o)
|
|
104
|
+
self == o
|
|
105
|
+
end
|
|
106
|
+
|
|
107
|
+
# Calculates hash code according to all attributes.
|
|
108
|
+
# @return [Integer] Hash code
|
|
109
|
+
def hash
|
|
110
|
+
[repo_hrefs, repo_versions_keeplist].hash
|
|
111
|
+
end
|
|
112
|
+
|
|
113
|
+
# Builds the object from hash
|
|
114
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
115
|
+
# @return [Object] Returns the model itself
|
|
116
|
+
def self.build_from_hash(attributes)
|
|
117
|
+
new.build_from_hash(attributes)
|
|
118
|
+
end
|
|
119
|
+
|
|
120
|
+
# Builds the object from hash
|
|
121
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
122
|
+
# @return [Object] Returns the model itself
|
|
123
|
+
def build_from_hash(attributes)
|
|
124
|
+
return nil unless attributes.is_a?(Hash)
|
|
125
|
+
self.class.openapi_types.each_pair do |key, type|
|
|
126
|
+
if type =~ /\AArray<(.*)>/i
|
|
127
|
+
# check to ensure the input is an array given that the attribute
|
|
128
|
+
# is documented as an array but the input is not
|
|
129
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
|
130
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
|
131
|
+
end
|
|
132
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
|
133
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
|
134
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
|
135
|
+
end
|
|
136
|
+
|
|
137
|
+
self
|
|
138
|
+
end
|
|
139
|
+
|
|
140
|
+
# Deserializes the data based on type
|
|
141
|
+
# @param string type Data type
|
|
142
|
+
# @param string value Value to be deserialized
|
|
143
|
+
# @return [Object] Deserialized data
|
|
144
|
+
def _deserialize(type, value)
|
|
145
|
+
case type.to_sym
|
|
146
|
+
when :DateTime
|
|
147
|
+
DateTime.parse(value)
|
|
148
|
+
when :Date
|
|
149
|
+
Date.parse(value)
|
|
150
|
+
when :String
|
|
151
|
+
value.to_s
|
|
152
|
+
when :Integer
|
|
153
|
+
value.to_i
|
|
154
|
+
when :Float
|
|
155
|
+
value.to_f
|
|
156
|
+
when :Boolean
|
|
157
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
|
158
|
+
true
|
|
159
|
+
else
|
|
160
|
+
false
|
|
161
|
+
end
|
|
162
|
+
when :Object
|
|
163
|
+
# generic object (usually a Hash), return directly
|
|
164
|
+
value
|
|
165
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
|
166
|
+
inner_type = Regexp.last_match[:inner_type]
|
|
167
|
+
value.map { |v| _deserialize(inner_type, v) }
|
|
168
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
|
169
|
+
k_type = Regexp.last_match[:k_type]
|
|
170
|
+
v_type = Regexp.last_match[:v_type]
|
|
171
|
+
{}.tap do |hash|
|
|
172
|
+
value.each do |k, v|
|
|
173
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
|
174
|
+
end
|
|
175
|
+
end
|
|
176
|
+
else # model
|
|
177
|
+
PulpcoreClient.const_get(type).build_from_hash(value)
|
|
178
|
+
end
|
|
179
|
+
end
|
|
180
|
+
|
|
181
|
+
# Returns the string representation of the object
|
|
182
|
+
# @return [String] String presentation of the object
|
|
183
|
+
def to_s
|
|
184
|
+
to_hash.to_s
|
|
185
|
+
end
|
|
186
|
+
|
|
187
|
+
# to_body is an alias to to_hash (backward compatibility)
|
|
188
|
+
# @return [Hash] Returns the object in the form of hash
|
|
189
|
+
def to_body
|
|
190
|
+
to_hash
|
|
191
|
+
end
|
|
192
|
+
|
|
193
|
+
# Returns the object in the form of hash
|
|
194
|
+
# @return [Hash] Returns the object in the form of hash
|
|
195
|
+
def to_hash
|
|
196
|
+
hash = {}
|
|
197
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
198
|
+
value = self.send(attr)
|
|
199
|
+
if value.nil?
|
|
200
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
|
201
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
202
|
+
end
|
|
203
|
+
|
|
204
|
+
hash[param] = _to_hash(value)
|
|
205
|
+
end
|
|
206
|
+
hash
|
|
207
|
+
end
|
|
208
|
+
|
|
209
|
+
# Outputs non-array value in the form of hash
|
|
210
|
+
# For object, use to_hash. Otherwise, just return the value
|
|
211
|
+
# @param [Object] value Any valid value
|
|
212
|
+
# @return [Hash] Returns the value in the form of hash
|
|
213
|
+
def _to_hash(value)
|
|
214
|
+
if value.is_a?(Array)
|
|
215
|
+
value.compact.map { |v| _to_hash(v) }
|
|
216
|
+
elsif value.is_a?(Hash)
|
|
217
|
+
{}.tap do |hash|
|
|
218
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
|
219
|
+
end
|
|
220
|
+
elsif value.respond_to? :to_hash
|
|
221
|
+
value.to_hash
|
|
222
|
+
else
|
|
223
|
+
value
|
|
224
|
+
end
|
|
225
|
+
end
|
|
226
|
+
end
|
|
227
|
+
end
|
|
@@ -33,8 +33,9 @@ module PulpcoreClient
|
|
|
33
33
|
attr_accessor :description
|
|
34
34
|
|
|
35
35
|
# Retain X versions of the repository. Default is null which retains all versions. This is provided as a tech preview in Pulp 3 and may change in the future.
|
|
36
|
-
attr_accessor :
|
|
36
|
+
attr_accessor :retain_repo_versions
|
|
37
37
|
|
|
38
|
+
# An optional remote to use by default when syncing.
|
|
38
39
|
attr_accessor :remote
|
|
39
40
|
|
|
40
41
|
# Attribute mapping from ruby-style variable name to JSON key.
|
|
@@ -47,7 +48,7 @@ module PulpcoreClient
|
|
|
47
48
|
:'latest_version_href' => :'latest_version_href',
|
|
48
49
|
:'name' => :'name',
|
|
49
50
|
:'description' => :'description',
|
|
50
|
-
:'
|
|
51
|
+
:'retain_repo_versions' => :'retain_repo_versions',
|
|
51
52
|
:'remote' => :'remote'
|
|
52
53
|
}
|
|
53
54
|
end
|
|
@@ -62,7 +63,7 @@ module PulpcoreClient
|
|
|
62
63
|
:'latest_version_href' => :'String',
|
|
63
64
|
:'name' => :'String',
|
|
64
65
|
:'description' => :'String',
|
|
65
|
-
:'
|
|
66
|
+
:'retain_repo_versions' => :'Integer',
|
|
66
67
|
:'remote' => :'String'
|
|
67
68
|
}
|
|
68
69
|
end
|
|
@@ -71,7 +72,7 @@ module PulpcoreClient
|
|
|
71
72
|
def self.openapi_nullable
|
|
72
73
|
Set.new([
|
|
73
74
|
:'description',
|
|
74
|
-
:'
|
|
75
|
+
:'retain_repo_versions',
|
|
75
76
|
:'remote'
|
|
76
77
|
])
|
|
77
78
|
end
|
|
@@ -119,8 +120,8 @@ module PulpcoreClient
|
|
|
119
120
|
self.description = attributes[:'description']
|
|
120
121
|
end
|
|
121
122
|
|
|
122
|
-
if attributes.key?(:'
|
|
123
|
-
self.
|
|
123
|
+
if attributes.key?(:'retain_repo_versions')
|
|
124
|
+
self.retain_repo_versions = attributes[:'retain_repo_versions']
|
|
124
125
|
end
|
|
125
126
|
|
|
126
127
|
if attributes.key?(:'remote')
|
|
@@ -136,8 +137,8 @@ module PulpcoreClient
|
|
|
136
137
|
invalid_properties.push('invalid value for "name", name cannot be nil.')
|
|
137
138
|
end
|
|
138
139
|
|
|
139
|
-
if !@
|
|
140
|
-
invalid_properties.push('invalid value for "
|
|
140
|
+
if !@retain_repo_versions.nil? && @retain_repo_versions < 1
|
|
141
|
+
invalid_properties.push('invalid value for "retain_repo_versions", must be greater than or equal to 1.')
|
|
141
142
|
end
|
|
142
143
|
|
|
143
144
|
invalid_properties
|
|
@@ -147,18 +148,18 @@ module PulpcoreClient
|
|
|
147
148
|
# @return true if the model is valid
|
|
148
149
|
def valid?
|
|
149
150
|
return false if @name.nil?
|
|
150
|
-
return false if !@
|
|
151
|
+
return false if !@retain_repo_versions.nil? && @retain_repo_versions < 1
|
|
151
152
|
true
|
|
152
153
|
end
|
|
153
154
|
|
|
154
155
|
# Custom attribute writer method with validation
|
|
155
|
-
# @param [Object]
|
|
156
|
-
def
|
|
157
|
-
if !
|
|
158
|
-
fail ArgumentError, 'invalid value for "
|
|
156
|
+
# @param [Object] retain_repo_versions Value to be assigned
|
|
157
|
+
def retain_repo_versions=(retain_repo_versions)
|
|
158
|
+
if !retain_repo_versions.nil? && retain_repo_versions < 1
|
|
159
|
+
fail ArgumentError, 'invalid value for "retain_repo_versions", must be greater than or equal to 1.'
|
|
159
160
|
end
|
|
160
161
|
|
|
161
|
-
@
|
|
162
|
+
@retain_repo_versions = retain_repo_versions
|
|
162
163
|
end
|
|
163
164
|
|
|
164
165
|
# Checks equality by comparing each attribute.
|
|
@@ -173,7 +174,7 @@ module PulpcoreClient
|
|
|
173
174
|
latest_version_href == o.latest_version_href &&
|
|
174
175
|
name == o.name &&
|
|
175
176
|
description == o.description &&
|
|
176
|
-
|
|
177
|
+
retain_repo_versions == o.retain_repo_versions &&
|
|
177
178
|
remote == o.remote
|
|
178
179
|
end
|
|
179
180
|
|
|
@@ -186,7 +187,7 @@ module PulpcoreClient
|
|
|
186
187
|
# Calculates hash code according to all attributes.
|
|
187
188
|
# @return [Integer] Hash code
|
|
188
189
|
def hash
|
|
189
|
-
[pulp_href, pulp_created, versions_href, pulp_labels, latest_version_href, name, description,
|
|
190
|
+
[pulp_href, pulp_created, versions_href, pulp_labels, latest_version_href, name, description, retain_repo_versions, remote].hash
|
|
190
191
|
end
|
|
191
192
|
|
|
192
193
|
# Builds the object from hash
|
data/lib/pulpcore_client.rb
CHANGED
|
@@ -27,18 +27,25 @@ require 'pulpcore_client/models/content_guard_response'
|
|
|
27
27
|
require 'pulpcore_client/models/content_summary_response'
|
|
28
28
|
require 'pulpcore_client/models/database_connection_response'
|
|
29
29
|
require 'pulpcore_client/models/evaluation_response'
|
|
30
|
+
require 'pulpcore_client/models/filesystem_export'
|
|
31
|
+
require 'pulpcore_client/models/filesystem_export_response'
|
|
32
|
+
require 'pulpcore_client/models/filesystem_exporter'
|
|
33
|
+
require 'pulpcore_client/models/filesystem_exporter_response'
|
|
30
34
|
require 'pulpcore_client/models/group'
|
|
31
35
|
require 'pulpcore_client/models/group_progress_report_response'
|
|
32
36
|
require 'pulpcore_client/models/group_response'
|
|
33
37
|
require 'pulpcore_client/models/group_user'
|
|
34
38
|
require 'pulpcore_client/models/group_user_response'
|
|
35
39
|
require 'pulpcore_client/models/import_response'
|
|
40
|
+
require 'pulpcore_client/models/method_enum'
|
|
36
41
|
require 'pulpcore_client/models/minimal_task_response'
|
|
37
42
|
require 'pulpcore_client/models/multiple_artifact_content_response'
|
|
38
43
|
require 'pulpcore_client/models/orphans_cleanup'
|
|
39
44
|
require 'pulpcore_client/models/paginated_access_policy_response_list'
|
|
40
45
|
require 'pulpcore_client/models/paginated_artifact_response_list'
|
|
41
46
|
require 'pulpcore_client/models/paginated_content_guard_response_list'
|
|
47
|
+
require 'pulpcore_client/models/paginated_filesystem_export_response_list'
|
|
48
|
+
require 'pulpcore_client/models/paginated_filesystem_exporter_response_list'
|
|
42
49
|
require 'pulpcore_client/models/paginated_group_response_list'
|
|
43
50
|
require 'pulpcore_client/models/paginated_group_user_response_list'
|
|
44
51
|
require 'pulpcore_client/models/paginated_import_response_list'
|
|
@@ -48,6 +55,7 @@ require 'pulpcore_client/models/paginated_publication_response_list'
|
|
|
48
55
|
require 'pulpcore_client/models/paginated_pulp_export_response_list'
|
|
49
56
|
require 'pulpcore_client/models/paginated_pulp_exporter_response_list'
|
|
50
57
|
require 'pulpcore_client/models/paginated_pulp_importer_response_list'
|
|
58
|
+
require 'pulpcore_client/models/paginated_rbac_content_guard_response_list'
|
|
51
59
|
require 'pulpcore_client/models/paginated_repository_response_list'
|
|
52
60
|
require 'pulpcore_client/models/paginated_repository_version_response_list'
|
|
53
61
|
require 'pulpcore_client/models/paginated_signing_service_response_list'
|
|
@@ -57,9 +65,11 @@ require 'pulpcore_client/models/paginated_upload_response_list'
|
|
|
57
65
|
require 'pulpcore_client/models/paginated_user_response_list'
|
|
58
66
|
require 'pulpcore_client/models/paginated_worker_response_list'
|
|
59
67
|
require 'pulpcore_client/models/patched_access_policy'
|
|
68
|
+
require 'pulpcore_client/models/patched_filesystem_exporter'
|
|
60
69
|
require 'pulpcore_client/models/patched_group'
|
|
61
70
|
require 'pulpcore_client/models/patched_pulp_exporter'
|
|
62
71
|
require 'pulpcore_client/models/patched_pulp_importer'
|
|
72
|
+
require 'pulpcore_client/models/patched_rbac_content_guard'
|
|
63
73
|
require 'pulpcore_client/models/patched_task_cancel'
|
|
64
74
|
require 'pulpcore_client/models/permission_response'
|
|
65
75
|
require 'pulpcore_client/models/progress_report_response'
|
|
@@ -73,6 +83,10 @@ require 'pulpcore_client/models/pulp_import_check'
|
|
|
73
83
|
require 'pulpcore_client/models/pulp_import_check_response'
|
|
74
84
|
require 'pulpcore_client/models/pulp_importer'
|
|
75
85
|
require 'pulpcore_client/models/pulp_importer_response'
|
|
86
|
+
require 'pulpcore_client/models/rbac_content_guard'
|
|
87
|
+
require 'pulpcore_client/models/rbac_content_guard_permission'
|
|
88
|
+
require 'pulpcore_client/models/rbac_content_guard_response'
|
|
89
|
+
require 'pulpcore_client/models/reclaim_space'
|
|
76
90
|
require 'pulpcore_client/models/redis_connection_response'
|
|
77
91
|
require 'pulpcore_client/models/repair'
|
|
78
92
|
require 'pulpcore_client/models/repository_response'
|
|
@@ -98,6 +112,9 @@ require 'pulpcore_client/api/access_policies_api'
|
|
|
98
112
|
require 'pulpcore_client/api/artifacts_api'
|
|
99
113
|
require 'pulpcore_client/api/content_api'
|
|
100
114
|
require 'pulpcore_client/api/contentguards_api'
|
|
115
|
+
require 'pulpcore_client/api/contentguards_rbac_api'
|
|
116
|
+
require 'pulpcore_client/api/exporters_filesystem_api'
|
|
117
|
+
require 'pulpcore_client/api/exporters_filesystem_exports_api'
|
|
101
118
|
require 'pulpcore_client/api/exporters_pulp_api'
|
|
102
119
|
require 'pulpcore_client/api/exporters_pulp_exports_api'
|
|
103
120
|
require 'pulpcore_client/api/groups_api'
|
|
@@ -112,6 +129,7 @@ require 'pulpcore_client/api/orphans_cleanup_api'
|
|
|
112
129
|
require 'pulpcore_client/api/publications_api'
|
|
113
130
|
require 'pulpcore_client/api/repair_api'
|
|
114
131
|
require 'pulpcore_client/api/repositories_api'
|
|
132
|
+
require 'pulpcore_client/api/repositories_reclaim_space_api'
|
|
115
133
|
require 'pulpcore_client/api/repository_versions_api'
|
|
116
134
|
require 'pulpcore_client/api/signing_services_api'
|
|
117
135
|
require 'pulpcore_client/api/status_api'
|
data/pulpcore_client.gemspec
CHANGED
|
@@ -21,13 +21,13 @@ Gem::Specification.new do |s|
|
|
|
21
21
|
s.platform = Gem::Platform::RUBY
|
|
22
22
|
s.authors = ["OpenAPI-Generator"]
|
|
23
23
|
s.email = ["pulp-list@redhat.com"]
|
|
24
|
-
s.homepage = "https://
|
|
24
|
+
s.homepage = "https://openapi-generator.tech"
|
|
25
25
|
s.summary = "Pulp 3 API Ruby Gem"
|
|
26
26
|
s.description = "Fetch, Upload, Organize, and Distribute Software Packages"
|
|
27
|
-
s.license = '
|
|
27
|
+
s.license = 'GPL-2.0+'
|
|
28
28
|
s.required_ruby_version = ">= 1.9"
|
|
29
29
|
|
|
30
|
-
s.add_runtime_dependency 'faraday', '>=
|
|
30
|
+
s.add_runtime_dependency 'faraday', '>= 0.14.0'
|
|
31
31
|
s.add_runtime_dependency 'json', '~> 2.1', '>= 2.1.0'
|
|
32
32
|
|
|
33
33
|
s.add_development_dependency 'rspec', '~> 3.6', '>= 3.6.0'
|