pulp_container_client 2.16.4 → 2.18.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +40 -6
- data/docs/ContainerContainerDistribution.md +7 -7
- data/docs/ContainerContainerDistributionResponse.md +10 -8
- data/docs/ContainerContainerPullThroughDistribution.md +35 -0
- data/docs/ContainerContainerPullThroughDistributionResponse.md +41 -0
- data/docs/ContainerContainerPullThroughRemote.md +57 -0
- data/docs/ContainerContainerPullThroughRemoteResponse.md +55 -0
- data/docs/{ContainerContainerRemoteResponseHiddenFields.md → ContainerContainerPullThroughRemoteResponseHiddenFields.md} +2 -2
- data/docs/ContainerContainerPushRepository.md +5 -5
- data/docs/ContainerContainerPushRepositoryResponse.md +13 -13
- data/docs/ContainerContainerRemote.md +1 -1
- data/docs/ContainerContainerRemoteResponse.md +2 -2
- data/docs/ContentBlobsApi.md +2 -0
- data/docs/ContentManifestsApi.md +2 -0
- data/docs/ContentSignaturesApi.md +2 -0
- data/docs/ContentTagsApi.md +2 -0
- data/docs/DistributionsPullThroughApi.md +736 -0
- data/docs/PaginatedcontainerContainerPullThroughDistributionResponseList.md +23 -0
- data/docs/PaginatedcontainerContainerPullThroughRemoteResponseList.md +23 -0
- data/docs/PatchedcontainerContainerDistribution.md +7 -7
- data/docs/PatchedcontainerContainerPullThroughDistribution.md +35 -0
- data/docs/PatchedcontainerContainerPullThroughRemote.md +57 -0
- data/docs/PatchedcontainerContainerPushRepository.md +5 -5
- data/docs/PatchedcontainerContainerRemote.md +1 -1
- data/docs/{PolicyEnum.md → Policy762Enum.md} +2 -2
- data/docs/Policy8e2Enum.md +16 -0
- data/docs/RemotesPullThroughApi.md +734 -0
- data/lib/pulp_container_client/api/content_blobs_api.rb +3 -0
- data/lib/pulp_container_client/api/content_manifests_api.rb +3 -0
- data/lib/pulp_container_client/api/content_signatures_api.rb +3 -0
- data/lib/pulp_container_client/api/content_tags_api.rb +3 -0
- data/lib/pulp_container_client/api/distributions_pull_through_api.rb +907 -0
- data/lib/pulp_container_client/api/remotes_pull_through_api.rb +904 -0
- data/lib/pulp_container_client/models/container_container_distribution.rb +26 -26
- data/lib/pulp_container_client/models/container_container_distribution_response.rb +43 -33
- data/lib/pulp_container_client/models/container_container_pull_through_distribution.rb +373 -0
- data/lib/pulp_container_client/models/container_container_pull_through_distribution_response.rb +349 -0
- data/lib/pulp_container_client/models/container_container_pull_through_remote.rb +668 -0
- data/lib/pulp_container_client/models/container_container_pull_through_remote_response.rb +496 -0
- data/lib/pulp_container_client/models/{container_container_remote_response_hidden_fields.rb → container_container_pull_through_remote_response_hidden_fields.rb} +3 -3
- data/lib/pulp_container_client/models/container_container_push_repository.rb +47 -47
- data/lib/pulp_container_client/models/container_container_push_repository_response.rb +56 -56
- data/lib/pulp_container_client/models/container_container_remote.rb +1 -1
- data/lib/pulp_container_client/models/container_container_remote_response.rb +2 -2
- data/lib/pulp_container_client/models/paginatedcontainer_container_pull_through_distribution_response_list.rb +237 -0
- data/lib/pulp_container_client/models/paginatedcontainer_container_pull_through_remote_response_list.rb +237 -0
- data/lib/pulp_container_client/models/patchedcontainer_container_distribution.rb +26 -26
- data/lib/pulp_container_client/models/patchedcontainer_container_pull_through_distribution.rb +350 -0
- data/lib/pulp_container_client/models/patchedcontainer_container_pull_through_remote.rb +650 -0
- data/lib/pulp_container_client/models/patchedcontainer_container_push_repository.rb +39 -39
- data/lib/pulp_container_client/models/patchedcontainer_container_remote.rb +1 -1
- data/lib/pulp_container_client/models/{policy_enum.rb → policy762_enum.rb} +3 -3
- data/lib/pulp_container_client/models/policy8e2_enum.rb +35 -0
- data/lib/pulp_container_client/version.rb +1 -1
- data/lib/pulp_container_client.rb +13 -2
- data/spec/api/content_blobs_api_spec.rb +1 -0
- data/spec/api/content_manifests_api_spec.rb +1 -0
- data/spec/api/content_signatures_api_spec.rb +1 -0
- data/spec/api/content_tags_api_spec.rb +1 -0
- data/spec/api/distributions_pull_through_api_spec.rb +215 -0
- data/spec/api/remotes_pull_through_api_spec.rb +214 -0
- data/spec/models/container_container_distribution_response_spec.rb +12 -6
- data/spec/models/container_container_distribution_spec.rb +4 -4
- data/spec/models/container_container_pull_through_distribution_response_spec.rb +113 -0
- data/spec/models/container_container_pull_through_distribution_spec.rb +95 -0
- data/spec/models/{container_container_remote_response_hidden_fields_spec.rb → container_container_pull_through_remote_response_hidden_fields_spec.rb} +6 -6
- data/spec/models/container_container_pull_through_remote_response_spec.rb +155 -0
- data/spec/models/container_container_pull_through_remote_spec.rb +161 -0
- data/spec/models/container_container_push_repository_response_spec.rb +7 -7
- data/spec/models/container_container_push_repository_spec.rb +4 -4
- data/spec/models/paginatedcontainer_container_pull_through_distribution_response_list_spec.rb +59 -0
- data/spec/models/paginatedcontainer_container_pull_through_remote_response_list_spec.rb +59 -0
- data/spec/models/patchedcontainer_container_distribution_spec.rb +4 -4
- data/spec/models/patchedcontainer_container_pull_through_distribution_spec.rb +95 -0
- data/spec/models/patchedcontainer_container_pull_through_remote_spec.rb +161 -0
- data/spec/models/patchedcontainer_container_push_repository_spec.rb +4 -4
- data/spec/models/{policy_enum_spec.rb → policy762_enum_spec.rb} +6 -6
- data/spec/models/policy8e2_enum_spec.rb +35 -0
- metadata +103 -59
@@ -0,0 +1,237 @@
|
|
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 PulpContainerClient
|
16
|
+
class PaginatedcontainerContainerPullThroughRemoteResponseList
|
17
|
+
attr_accessor :count
|
18
|
+
|
19
|
+
attr_accessor :_next
|
20
|
+
|
21
|
+
attr_accessor :previous
|
22
|
+
|
23
|
+
attr_accessor :results
|
24
|
+
|
25
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
26
|
+
def self.attribute_map
|
27
|
+
{
|
28
|
+
:'count' => :'count',
|
29
|
+
:'_next' => :'next',
|
30
|
+
:'previous' => :'previous',
|
31
|
+
:'results' => :'results'
|
32
|
+
}
|
33
|
+
end
|
34
|
+
|
35
|
+
# Attribute type mapping.
|
36
|
+
def self.openapi_types
|
37
|
+
{
|
38
|
+
:'count' => :'Integer',
|
39
|
+
:'_next' => :'String',
|
40
|
+
:'previous' => :'String',
|
41
|
+
:'results' => :'Array<ContainerContainerPullThroughRemoteResponse>'
|
42
|
+
}
|
43
|
+
end
|
44
|
+
|
45
|
+
# List of attributes with nullable: true
|
46
|
+
def self.openapi_nullable
|
47
|
+
Set.new([
|
48
|
+
:'_next',
|
49
|
+
:'previous',
|
50
|
+
])
|
51
|
+
end
|
52
|
+
|
53
|
+
# Initializes the object
|
54
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
55
|
+
def initialize(attributes = {})
|
56
|
+
if (!attributes.is_a?(Hash))
|
57
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `PulpContainerClient::PaginatedcontainerContainerPullThroughRemoteResponseList` initialize method"
|
58
|
+
end
|
59
|
+
|
60
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
61
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
62
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
63
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `PulpContainerClient::PaginatedcontainerContainerPullThroughRemoteResponseList`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
64
|
+
end
|
65
|
+
h[k.to_sym] = v
|
66
|
+
}
|
67
|
+
|
68
|
+
if attributes.key?(:'count')
|
69
|
+
self.count = attributes[:'count']
|
70
|
+
end
|
71
|
+
|
72
|
+
if attributes.key?(:'_next')
|
73
|
+
self._next = attributes[:'_next']
|
74
|
+
end
|
75
|
+
|
76
|
+
if attributes.key?(:'previous')
|
77
|
+
self.previous = attributes[:'previous']
|
78
|
+
end
|
79
|
+
|
80
|
+
if attributes.key?(:'results')
|
81
|
+
if (value = attributes[:'results']).is_a?(Array)
|
82
|
+
self.results = value
|
83
|
+
end
|
84
|
+
end
|
85
|
+
end
|
86
|
+
|
87
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
88
|
+
# @return Array for valid properties with the reasons
|
89
|
+
def list_invalid_properties
|
90
|
+
invalid_properties = Array.new
|
91
|
+
invalid_properties
|
92
|
+
end
|
93
|
+
|
94
|
+
# Check to see if the all the properties in the model are valid
|
95
|
+
# @return true if the model is valid
|
96
|
+
def valid?
|
97
|
+
true
|
98
|
+
end
|
99
|
+
|
100
|
+
# Checks equality by comparing each attribute.
|
101
|
+
# @param [Object] Object to be compared
|
102
|
+
def ==(o)
|
103
|
+
return true if self.equal?(o)
|
104
|
+
self.class == o.class &&
|
105
|
+
count == o.count &&
|
106
|
+
_next == o._next &&
|
107
|
+
previous == o.previous &&
|
108
|
+
results == o.results
|
109
|
+
end
|
110
|
+
|
111
|
+
# @see the `==` method
|
112
|
+
# @param [Object] Object to be compared
|
113
|
+
def eql?(o)
|
114
|
+
self == o
|
115
|
+
end
|
116
|
+
|
117
|
+
# Calculates hash code according to all attributes.
|
118
|
+
# @return [Integer] Hash code
|
119
|
+
def hash
|
120
|
+
[count, _next, previous, results].hash
|
121
|
+
end
|
122
|
+
|
123
|
+
# Builds the object from hash
|
124
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
125
|
+
# @return [Object] Returns the model itself
|
126
|
+
def self.build_from_hash(attributes)
|
127
|
+
new.build_from_hash(attributes)
|
128
|
+
end
|
129
|
+
|
130
|
+
# Builds the object from hash
|
131
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
132
|
+
# @return [Object] Returns the model itself
|
133
|
+
def build_from_hash(attributes)
|
134
|
+
return nil unless attributes.is_a?(Hash)
|
135
|
+
self.class.openapi_types.each_pair do |key, type|
|
136
|
+
if type =~ /\AArray<(.*)>/i
|
137
|
+
# check to ensure the input is an array given that the attribute
|
138
|
+
# is documented as an array but the input is not
|
139
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
140
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
141
|
+
end
|
142
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
143
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
144
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
145
|
+
end
|
146
|
+
|
147
|
+
self
|
148
|
+
end
|
149
|
+
|
150
|
+
# Deserializes the data based on type
|
151
|
+
# @param string type Data type
|
152
|
+
# @param string value Value to be deserialized
|
153
|
+
# @return [Object] Deserialized data
|
154
|
+
def _deserialize(type, value)
|
155
|
+
case type.to_sym
|
156
|
+
when :DateTime
|
157
|
+
DateTime.parse(value)
|
158
|
+
when :Date
|
159
|
+
Date.parse(value)
|
160
|
+
when :String
|
161
|
+
value.to_s
|
162
|
+
when :Integer
|
163
|
+
value.to_i
|
164
|
+
when :Float
|
165
|
+
value.to_f
|
166
|
+
when :Boolean
|
167
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
168
|
+
true
|
169
|
+
else
|
170
|
+
false
|
171
|
+
end
|
172
|
+
when :Object
|
173
|
+
# generic object (usually a Hash), return directly
|
174
|
+
value
|
175
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
176
|
+
inner_type = Regexp.last_match[:inner_type]
|
177
|
+
value.map { |v| _deserialize(inner_type, v) }
|
178
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
179
|
+
k_type = Regexp.last_match[:k_type]
|
180
|
+
v_type = Regexp.last_match[:v_type]
|
181
|
+
{}.tap do |hash|
|
182
|
+
value.each do |k, v|
|
183
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
184
|
+
end
|
185
|
+
end
|
186
|
+
else # model
|
187
|
+
PulpContainerClient.const_get(type).build_from_hash(value)
|
188
|
+
end
|
189
|
+
end
|
190
|
+
|
191
|
+
# Returns the string representation of the object
|
192
|
+
# @return [String] String presentation of the object
|
193
|
+
def to_s
|
194
|
+
to_hash.to_s
|
195
|
+
end
|
196
|
+
|
197
|
+
# to_body is an alias to to_hash (backward compatibility)
|
198
|
+
# @return [Hash] Returns the object in the form of hash
|
199
|
+
def to_body
|
200
|
+
to_hash
|
201
|
+
end
|
202
|
+
|
203
|
+
# Returns the object in the form of hash
|
204
|
+
# @return [Hash] Returns the object in the form of hash
|
205
|
+
def to_hash
|
206
|
+
hash = {}
|
207
|
+
self.class.attribute_map.each_pair do |attr, param|
|
208
|
+
value = self.send(attr)
|
209
|
+
if value.nil?
|
210
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
211
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
212
|
+
end
|
213
|
+
|
214
|
+
hash[param] = _to_hash(value)
|
215
|
+
end
|
216
|
+
hash
|
217
|
+
end
|
218
|
+
|
219
|
+
# Outputs non-array value in the form of hash
|
220
|
+
# For object, use to_hash. Otherwise, just return the value
|
221
|
+
# @param [Object] value Any valid value
|
222
|
+
# @return [Hash] Returns the value in the form of hash
|
223
|
+
def _to_hash(value)
|
224
|
+
if value.is_a?(Array)
|
225
|
+
value.compact.map { |v| _to_hash(v) }
|
226
|
+
elsif value.is_a?(Hash)
|
227
|
+
{}.tap do |hash|
|
228
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
229
|
+
end
|
230
|
+
elsif value.respond_to? :to_hash
|
231
|
+
value.to_hash
|
232
|
+
else
|
233
|
+
value
|
234
|
+
end
|
235
|
+
end
|
236
|
+
end
|
237
|
+
end
|
@@ -15,22 +15,22 @@ require 'date'
|
|
15
15
|
module PulpContainerClient
|
16
16
|
# A serializer for ContainerDistribution.
|
17
17
|
class PatchedcontainerContainerDistribution
|
18
|
+
# An optional content-guard. If none is specified, a default one will be used.
|
19
|
+
attr_accessor :content_guard
|
20
|
+
|
18
21
|
# The base (relative) path component of the published url. Avoid paths that overlap with other distribution base paths (e.g. \"foo\" and \"foo/bar\")
|
19
22
|
attr_accessor :base_path
|
20
23
|
|
21
|
-
# The latest RepositoryVersion for this Repository will be served.
|
22
|
-
attr_accessor :repository
|
23
|
-
|
24
24
|
# Whether this distribution should be shown in the content app.
|
25
25
|
attr_accessor :hidden
|
26
26
|
|
27
|
-
|
28
|
-
attr_accessor :content_guard
|
27
|
+
attr_accessor :pulp_labels
|
29
28
|
|
30
29
|
# A unique name. Ex, `rawhide` and `stable`.
|
31
30
|
attr_accessor :name
|
32
31
|
|
33
|
-
|
32
|
+
# The latest RepositoryVersion for this Repository will be served.
|
33
|
+
attr_accessor :repository
|
34
34
|
|
35
35
|
# RepositoryVersion to be served
|
36
36
|
attr_accessor :repository_version
|
@@ -44,12 +44,12 @@ module PulpContainerClient
|
|
44
44
|
# Attribute mapping from ruby-style variable name to JSON key.
|
45
45
|
def self.attribute_map
|
46
46
|
{
|
47
|
+
:'content_guard' => :'content_guard',
|
47
48
|
:'base_path' => :'base_path',
|
48
|
-
:'repository' => :'repository',
|
49
49
|
:'hidden' => :'hidden',
|
50
|
-
:'content_guard' => :'content_guard',
|
51
|
-
:'name' => :'name',
|
52
50
|
:'pulp_labels' => :'pulp_labels',
|
51
|
+
:'name' => :'name',
|
52
|
+
:'repository' => :'repository',
|
53
53
|
:'repository_version' => :'repository_version',
|
54
54
|
:'private' => :'private',
|
55
55
|
:'description' => :'description'
|
@@ -59,12 +59,12 @@ module PulpContainerClient
|
|
59
59
|
# Attribute type mapping.
|
60
60
|
def self.openapi_types
|
61
61
|
{
|
62
|
+
:'content_guard' => :'String',
|
62
63
|
:'base_path' => :'String',
|
63
|
-
:'repository' => :'String',
|
64
64
|
:'hidden' => :'Boolean',
|
65
|
-
:'content_guard' => :'String',
|
66
|
-
:'name' => :'String',
|
67
65
|
:'pulp_labels' => :'Hash<String, String>',
|
66
|
+
:'name' => :'String',
|
67
|
+
:'repository' => :'String',
|
68
68
|
:'repository_version' => :'String',
|
69
69
|
:'private' => :'Boolean',
|
70
70
|
:'description' => :'String'
|
@@ -95,12 +95,12 @@ module PulpContainerClient
|
|
95
95
|
h[k.to_sym] = v
|
96
96
|
}
|
97
97
|
|
98
|
-
if attributes.key?(:'
|
99
|
-
self.
|
98
|
+
if attributes.key?(:'content_guard')
|
99
|
+
self.content_guard = attributes[:'content_guard']
|
100
100
|
end
|
101
101
|
|
102
|
-
if attributes.key?(:'
|
103
|
-
self.
|
102
|
+
if attributes.key?(:'base_path')
|
103
|
+
self.base_path = attributes[:'base_path']
|
104
104
|
end
|
105
105
|
|
106
106
|
if attributes.key?(:'hidden')
|
@@ -109,18 +109,18 @@ module PulpContainerClient
|
|
109
109
|
self.hidden = false
|
110
110
|
end
|
111
111
|
|
112
|
-
if attributes.key?(:'
|
113
|
-
|
112
|
+
if attributes.key?(:'pulp_labels')
|
113
|
+
if (value = attributes[:'pulp_labels']).is_a?(Hash)
|
114
|
+
self.pulp_labels = value
|
115
|
+
end
|
114
116
|
end
|
115
117
|
|
116
118
|
if attributes.key?(:'name')
|
117
119
|
self.name = attributes[:'name']
|
118
120
|
end
|
119
121
|
|
120
|
-
if attributes.key?(:'
|
121
|
-
|
122
|
-
self.pulp_labels = value
|
123
|
-
end
|
122
|
+
if attributes.key?(:'repository')
|
123
|
+
self.repository = attributes[:'repository']
|
124
124
|
end
|
125
125
|
|
126
126
|
if attributes.key?(:'repository_version')
|
@@ -199,12 +199,12 @@ module PulpContainerClient
|
|
199
199
|
def ==(o)
|
200
200
|
return true if self.equal?(o)
|
201
201
|
self.class == o.class &&
|
202
|
+
content_guard == o.content_guard &&
|
202
203
|
base_path == o.base_path &&
|
203
|
-
repository == o.repository &&
|
204
204
|
hidden == o.hidden &&
|
205
|
-
content_guard == o.content_guard &&
|
206
|
-
name == o.name &&
|
207
205
|
pulp_labels == o.pulp_labels &&
|
206
|
+
name == o.name &&
|
207
|
+
repository == o.repository &&
|
208
208
|
repository_version == o.repository_version &&
|
209
209
|
private == o.private &&
|
210
210
|
description == o.description
|
@@ -219,7 +219,7 @@ module PulpContainerClient
|
|
219
219
|
# Calculates hash code according to all attributes.
|
220
220
|
# @return [Integer] Hash code
|
221
221
|
def hash
|
222
|
-
[
|
222
|
+
[content_guard, base_path, hidden, pulp_labels, name, repository, repository_version, private, description].hash
|
223
223
|
end
|
224
224
|
|
225
225
|
# Builds the object from hash
|