pulp_ostree_client 2.2.1 → 2.3.1
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 +23 -4
- data/docs/ContentCommitsApi.md +2 -0
- data/docs/ContentConfigsApi.md +2 -0
- data/docs/ContentContentApi.md +56 -0
- data/docs/ContentObjectsApi.md +2 -0
- data/docs/ContentRefsApi.md +2 -0
- data/docs/ContentSummariesApi.md +2 -0
- data/docs/DistributionsOstreeApi.md +232 -0
- data/docs/MyPermissionsResponse.md +17 -0
- data/docs/NestedRole.md +21 -0
- data/docs/NestedRoleResponse.md +21 -0
- data/docs/ObjectRolesResponse.md +17 -0
- data/docs/OstreeOstreeCommitResponse.md +2 -0
- data/docs/OstreeOstreeConfigResponse.md +2 -0
- data/docs/OstreeOstreeContent.md +23 -0
- data/docs/OstreeOstreeContentResponse.md +2 -0
- data/docs/OstreeOstreeDistributionResponse.md +2 -0
- data/docs/OstreeOstreeObjectResponse.md +2 -0
- data/docs/OstreeOstreeRefResponse.md +2 -0
- data/docs/OstreeOstreeRemoteResponse.md +2 -2
- data/docs/OstreeOstreeRemoteResponseHiddenFields.md +2 -2
- data/docs/OstreeOstreeRepositoryResponse.md +2 -0
- data/docs/OstreeOstreeSummaryResponse.md +2 -0
- data/docs/PaginatedRepositoryVersionResponseList.md +2 -2
- data/docs/PaginatedostreeOstreeCommitResponseList.md +2 -2
- data/docs/PaginatedostreeOstreeConfigResponseList.md +2 -2
- data/docs/PaginatedostreeOstreeContentResponseList.md +2 -2
- data/docs/PaginatedostreeOstreeDistributionResponseList.md +2 -2
- data/docs/PaginatedostreeOstreeObjectResponseList.md +2 -2
- data/docs/PaginatedostreeOstreeRefResponseList.md +2 -2
- data/docs/PaginatedostreeOstreeRemoteResponseList.md +2 -2
- data/docs/PaginatedostreeOstreeRepositoryResponseList.md +2 -2
- data/docs/PaginatedostreeOstreeSummaryResponseList.md +2 -2
- data/docs/RemotesOstreeApi.md +232 -0
- data/docs/RepositoriesOstreeApi.md +232 -0
- data/docs/RepositoryVersionResponse.md +2 -0
- data/lib/pulp_ostree_client/api/content_commits_api.rb +3 -0
- data/lib/pulp_ostree_client/api/content_configs_api.rb +3 -0
- data/lib/pulp_ostree_client/api/content_content_api.rb +67 -0
- data/lib/pulp_ostree_client/api/content_objects_api.rb +3 -0
- data/lib/pulp_ostree_client/api/content_refs_api.rb +3 -0
- data/lib/pulp_ostree_client/api/content_summaries_api.rb +3 -0
- data/lib/pulp_ostree_client/api/distributions_ostree_api.rb +276 -0
- data/lib/pulp_ostree_client/api/remotes_ostree_api.rb +276 -0
- data/lib/pulp_ostree_client/api/repositories_ostree_api.rb +276 -0
- data/lib/pulp_ostree_client/models/my_permissions_response.rb +213 -0
- data/lib/pulp_ostree_client/models/nested_role.rb +253 -0
- data/lib/pulp_ostree_client/models/nested_role_response.rb +234 -0
- data/lib/pulp_ostree_client/models/object_roles_response.rb +213 -0
- data/lib/pulp_ostree_client/models/ostree_ostree_commit_response.rb +11 -1
- data/lib/pulp_ostree_client/models/ostree_ostree_config_response.rb +11 -1
- data/lib/pulp_ostree_client/models/ostree_ostree_content.rb +289 -0
- data/lib/pulp_ostree_client/models/ostree_ostree_content_response.rb +11 -1
- data/lib/pulp_ostree_client/models/ostree_ostree_distribution_response.rb +11 -1
- data/lib/pulp_ostree_client/models/ostree_ostree_object_response.rb +11 -1
- data/lib/pulp_ostree_client/models/ostree_ostree_ref_response.rb +11 -1
- data/lib/pulp_ostree_client/models/ostree_ostree_remote_response.rb +11 -11
- data/lib/pulp_ostree_client/models/ostree_ostree_remote_response_hidden_fields.rb +10 -0
- data/lib/pulp_ostree_client/models/ostree_ostree_repository_response.rb +11 -1
- data/lib/pulp_ostree_client/models/ostree_ostree_summary_response.rb +11 -1
- data/lib/pulp_ostree_client/models/paginated_repository_version_response_list.rb +10 -0
- data/lib/pulp_ostree_client/models/paginatedostree_ostree_commit_response_list.rb +10 -0
- data/lib/pulp_ostree_client/models/paginatedostree_ostree_config_response_list.rb +10 -0
- data/lib/pulp_ostree_client/models/paginatedostree_ostree_content_response_list.rb +10 -0
- data/lib/pulp_ostree_client/models/paginatedostree_ostree_distribution_response_list.rb +10 -0
- data/lib/pulp_ostree_client/models/paginatedostree_ostree_object_response_list.rb +10 -0
- data/lib/pulp_ostree_client/models/paginatedostree_ostree_ref_response_list.rb +10 -0
- data/lib/pulp_ostree_client/models/paginatedostree_ostree_remote_response_list.rb +10 -0
- data/lib/pulp_ostree_client/models/paginatedostree_ostree_repository_response_list.rb +10 -0
- data/lib/pulp_ostree_client/models/paginatedostree_ostree_summary_response_list.rb +10 -0
- data/lib/pulp_ostree_client/models/repository_version_response.rb +11 -1
- data/lib/pulp_ostree_client/version.rb +1 -1
- data/lib/pulp_ostree_client.rb +5 -0
- data/spec/api/content_commits_api_spec.rb +1 -0
- data/spec/api/content_configs_api_spec.rb +1 -0
- data/spec/api/content_content_api_spec.rb +13 -0
- data/spec/api/content_objects_api_spec.rb +1 -0
- data/spec/api/content_refs_api_spec.rb +1 -0
- data/spec/api/content_summaries_api_spec.rb +1 -0
- data/spec/api/distributions_ostree_api_spec.rb +54 -0
- data/spec/api/remotes_ostree_api_spec.rb +54 -0
- data/spec/api/repositories_ostree_api_spec.rb +54 -0
- data/spec/models/my_permissions_response_spec.rb +41 -0
- data/spec/models/nested_role_response_spec.rb +53 -0
- data/spec/models/nested_role_spec.rb +53 -0
- data/spec/models/object_roles_response_spec.rb +41 -0
- data/spec/models/ostree_ostree_commit_response_spec.rb +6 -0
- data/spec/models/ostree_ostree_config_response_spec.rb +6 -0
- data/spec/models/ostree_ostree_content_response_spec.rb +6 -0
- data/spec/models/ostree_ostree_content_spec.rb +59 -0
- data/spec/models/ostree_ostree_distribution_response_spec.rb +6 -0
- data/spec/models/ostree_ostree_object_response_spec.rb +6 -0
- data/spec/models/ostree_ostree_ref_response_spec.rb +6 -0
- data/spec/models/ostree_ostree_remote_response_spec.rb +6 -6
- data/spec/models/ostree_ostree_repository_response_spec.rb +6 -0
- data/spec/models/ostree_ostree_summary_response_spec.rb +6 -0
- data/spec/models/repository_version_response_spec.rb +6 -0
- metadata +55 -35
@@ -20,6 +20,9 @@ module PulpOstreeClient
|
|
20
20
|
# Timestamp of creation.
|
21
21
|
attr_accessor :pulp_created
|
22
22
|
|
23
|
+
# Timestamp of the last time this resource was updated. Note: for immutable resources - like content, repository versions, and publication - pulp_created and pulp_last_updated dates will be the same.
|
24
|
+
attr_accessor :pulp_last_updated
|
25
|
+
|
23
26
|
# Artifact file representing the physical content
|
24
27
|
attr_accessor :artifact
|
25
28
|
|
@@ -37,6 +40,7 @@ module PulpOstreeClient
|
|
37
40
|
{
|
38
41
|
:'pulp_href' => :'pulp_href',
|
39
42
|
:'pulp_created' => :'pulp_created',
|
43
|
+
:'pulp_last_updated' => :'pulp_last_updated',
|
40
44
|
:'artifact' => :'artifact',
|
41
45
|
:'relative_path' => :'relative_path',
|
42
46
|
:'parent_commit' => :'parent_commit',
|
@@ -50,6 +54,7 @@ module PulpOstreeClient
|
|
50
54
|
{
|
51
55
|
:'pulp_href' => :'String',
|
52
56
|
:'pulp_created' => :'DateTime',
|
57
|
+
:'pulp_last_updated' => :'DateTime',
|
53
58
|
:'artifact' => :'String',
|
54
59
|
:'relative_path' => :'String',
|
55
60
|
:'parent_commit' => :'String',
|
@@ -88,6 +93,10 @@ module PulpOstreeClient
|
|
88
93
|
self.pulp_created = attributes[:'pulp_created']
|
89
94
|
end
|
90
95
|
|
96
|
+
if attributes.key?(:'pulp_last_updated')
|
97
|
+
self.pulp_last_updated = attributes[:'pulp_last_updated']
|
98
|
+
end
|
99
|
+
|
91
100
|
if attributes.key?(:'artifact')
|
92
101
|
self.artifact = attributes[:'artifact']
|
93
102
|
end
|
@@ -151,6 +160,7 @@ module PulpOstreeClient
|
|
151
160
|
self.class == o.class &&
|
152
161
|
pulp_href == o.pulp_href &&
|
153
162
|
pulp_created == o.pulp_created &&
|
163
|
+
pulp_last_updated == o.pulp_last_updated &&
|
154
164
|
artifact == o.artifact &&
|
155
165
|
relative_path == o.relative_path &&
|
156
166
|
parent_commit == o.parent_commit &&
|
@@ -167,7 +177,7 @@ module PulpOstreeClient
|
|
167
177
|
# Calculates hash code according to all attributes.
|
168
178
|
# @return [Integer] Hash code
|
169
179
|
def hash
|
170
|
-
[pulp_href, pulp_created, artifact, relative_path, parent_commit, checksum, objs].hash
|
180
|
+
[pulp_href, pulp_created, pulp_last_updated, artifact, relative_path, parent_commit, checksum, objs].hash
|
171
181
|
end
|
172
182
|
|
173
183
|
# Builds the object from hash
|
@@ -20,6 +20,9 @@ module PulpOstreeClient
|
|
20
20
|
# Timestamp of creation.
|
21
21
|
attr_accessor :pulp_created
|
22
22
|
|
23
|
+
# Timestamp of the last time this resource was updated. Note: for immutable resources - like content, repository versions, and publication - pulp_created and pulp_last_updated dates will be the same.
|
24
|
+
attr_accessor :pulp_last_updated
|
25
|
+
|
23
26
|
# Artifact file representing the physical content
|
24
27
|
attr_accessor :artifact
|
25
28
|
|
@@ -31,6 +34,7 @@ module PulpOstreeClient
|
|
31
34
|
{
|
32
35
|
:'pulp_href' => :'pulp_href',
|
33
36
|
:'pulp_created' => :'pulp_created',
|
37
|
+
:'pulp_last_updated' => :'pulp_last_updated',
|
34
38
|
:'artifact' => :'artifact',
|
35
39
|
:'relative_path' => :'relative_path'
|
36
40
|
}
|
@@ -41,6 +45,7 @@ module PulpOstreeClient
|
|
41
45
|
{
|
42
46
|
:'pulp_href' => :'String',
|
43
47
|
:'pulp_created' => :'DateTime',
|
48
|
+
:'pulp_last_updated' => :'DateTime',
|
44
49
|
:'artifact' => :'String',
|
45
50
|
:'relative_path' => :'String'
|
46
51
|
}
|
@@ -75,6 +80,10 @@ module PulpOstreeClient
|
|
75
80
|
self.pulp_created = attributes[:'pulp_created']
|
76
81
|
end
|
77
82
|
|
83
|
+
if attributes.key?(:'pulp_last_updated')
|
84
|
+
self.pulp_last_updated = attributes[:'pulp_last_updated']
|
85
|
+
end
|
86
|
+
|
78
87
|
if attributes.key?(:'artifact')
|
79
88
|
self.artifact = attributes[:'artifact']
|
80
89
|
end
|
@@ -114,6 +123,7 @@ module PulpOstreeClient
|
|
114
123
|
self.class == o.class &&
|
115
124
|
pulp_href == o.pulp_href &&
|
116
125
|
pulp_created == o.pulp_created &&
|
126
|
+
pulp_last_updated == o.pulp_last_updated &&
|
117
127
|
artifact == o.artifact &&
|
118
128
|
relative_path == o.relative_path
|
119
129
|
end
|
@@ -127,7 +137,7 @@ module PulpOstreeClient
|
|
127
137
|
# Calculates hash code according to all attributes.
|
128
138
|
# @return [Integer] Hash code
|
129
139
|
def hash
|
130
|
-
[pulp_href, pulp_created, artifact, relative_path].hash
|
140
|
+
[pulp_href, pulp_created, pulp_last_updated, artifact, relative_path].hash
|
131
141
|
end
|
132
142
|
|
133
143
|
# Builds the object from hash
|
@@ -0,0 +1,289 @@
|
|
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 PulpOstreeClient
|
16
|
+
# A Serializer class for uncategorized content units (e.g., static deltas).
|
17
|
+
class OstreeOstreeContent
|
18
|
+
# A URI of a repository the new content unit should be associated with.
|
19
|
+
attr_accessor :repository
|
20
|
+
|
21
|
+
# Artifact file representing the physical content
|
22
|
+
attr_accessor :artifact
|
23
|
+
|
24
|
+
attr_accessor :relative_path
|
25
|
+
|
26
|
+
attr_accessor :digest
|
27
|
+
|
28
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
29
|
+
def self.attribute_map
|
30
|
+
{
|
31
|
+
:'repository' => :'repository',
|
32
|
+
:'artifact' => :'artifact',
|
33
|
+
:'relative_path' => :'relative_path',
|
34
|
+
:'digest' => :'digest'
|
35
|
+
}
|
36
|
+
end
|
37
|
+
|
38
|
+
# Attribute type mapping.
|
39
|
+
def self.openapi_types
|
40
|
+
{
|
41
|
+
:'repository' => :'String',
|
42
|
+
:'artifact' => :'String',
|
43
|
+
:'relative_path' => :'String',
|
44
|
+
:'digest' => :'String'
|
45
|
+
}
|
46
|
+
end
|
47
|
+
|
48
|
+
# List of attributes with nullable: true
|
49
|
+
def self.openapi_nullable
|
50
|
+
Set.new([
|
51
|
+
])
|
52
|
+
end
|
53
|
+
|
54
|
+
# Initializes the object
|
55
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
56
|
+
def initialize(attributes = {})
|
57
|
+
if (!attributes.is_a?(Hash))
|
58
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `PulpOstreeClient::OstreeOstreeContent` initialize method"
|
59
|
+
end
|
60
|
+
|
61
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
62
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
63
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
64
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `PulpOstreeClient::OstreeOstreeContent`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
65
|
+
end
|
66
|
+
h[k.to_sym] = v
|
67
|
+
}
|
68
|
+
|
69
|
+
if attributes.key?(:'repository')
|
70
|
+
self.repository = attributes[:'repository']
|
71
|
+
end
|
72
|
+
|
73
|
+
if attributes.key?(:'artifact')
|
74
|
+
self.artifact = attributes[:'artifact']
|
75
|
+
end
|
76
|
+
|
77
|
+
if attributes.key?(:'relative_path')
|
78
|
+
self.relative_path = attributes[:'relative_path']
|
79
|
+
end
|
80
|
+
|
81
|
+
if attributes.key?(:'digest')
|
82
|
+
self.digest = attributes[:'digest']
|
83
|
+
end
|
84
|
+
end
|
85
|
+
|
86
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
87
|
+
# @return Array for valid properties with the reasons
|
88
|
+
def list_invalid_properties
|
89
|
+
invalid_properties = Array.new
|
90
|
+
if @artifact.nil?
|
91
|
+
invalid_properties.push('invalid value for "artifact", artifact cannot be nil.')
|
92
|
+
end
|
93
|
+
|
94
|
+
if @relative_path.nil?
|
95
|
+
invalid_properties.push('invalid value for "relative_path", relative_path cannot be nil.')
|
96
|
+
end
|
97
|
+
|
98
|
+
if @relative_path.to_s.length < 1
|
99
|
+
invalid_properties.push('invalid value for "relative_path", the character length must be great than or equal to 1.')
|
100
|
+
end
|
101
|
+
|
102
|
+
if @digest.nil?
|
103
|
+
invalid_properties.push('invalid value for "digest", digest cannot be nil.')
|
104
|
+
end
|
105
|
+
|
106
|
+
if @digest.to_s.length < 1
|
107
|
+
invalid_properties.push('invalid value for "digest", the character length must be great than or equal to 1.')
|
108
|
+
end
|
109
|
+
|
110
|
+
invalid_properties
|
111
|
+
end
|
112
|
+
|
113
|
+
# Check to see if the all the properties in the model are valid
|
114
|
+
# @return true if the model is valid
|
115
|
+
def valid?
|
116
|
+
return false if @artifact.nil?
|
117
|
+
return false if @relative_path.nil?
|
118
|
+
return false if @relative_path.to_s.length < 1
|
119
|
+
return false if @digest.nil?
|
120
|
+
return false if @digest.to_s.length < 1
|
121
|
+
true
|
122
|
+
end
|
123
|
+
|
124
|
+
# Custom attribute writer method with validation
|
125
|
+
# @param [Object] relative_path Value to be assigned
|
126
|
+
def relative_path=(relative_path)
|
127
|
+
if relative_path.nil?
|
128
|
+
fail ArgumentError, 'relative_path cannot be nil'
|
129
|
+
end
|
130
|
+
|
131
|
+
if relative_path.to_s.length < 1
|
132
|
+
fail ArgumentError, 'invalid value for "relative_path", the character length must be great than or equal to 1.'
|
133
|
+
end
|
134
|
+
|
135
|
+
@relative_path = relative_path
|
136
|
+
end
|
137
|
+
|
138
|
+
# Custom attribute writer method with validation
|
139
|
+
# @param [Object] digest Value to be assigned
|
140
|
+
def digest=(digest)
|
141
|
+
if digest.nil?
|
142
|
+
fail ArgumentError, 'digest cannot be nil'
|
143
|
+
end
|
144
|
+
|
145
|
+
if digest.to_s.length < 1
|
146
|
+
fail ArgumentError, 'invalid value for "digest", the character length must be great than or equal to 1.'
|
147
|
+
end
|
148
|
+
|
149
|
+
@digest = digest
|
150
|
+
end
|
151
|
+
|
152
|
+
# Checks equality by comparing each attribute.
|
153
|
+
# @param [Object] Object to be compared
|
154
|
+
def ==(o)
|
155
|
+
return true if self.equal?(o)
|
156
|
+
self.class == o.class &&
|
157
|
+
repository == o.repository &&
|
158
|
+
artifact == o.artifact &&
|
159
|
+
relative_path == o.relative_path &&
|
160
|
+
digest == o.digest
|
161
|
+
end
|
162
|
+
|
163
|
+
# @see the `==` method
|
164
|
+
# @param [Object] Object to be compared
|
165
|
+
def eql?(o)
|
166
|
+
self == o
|
167
|
+
end
|
168
|
+
|
169
|
+
# Calculates hash code according to all attributes.
|
170
|
+
# @return [Integer] Hash code
|
171
|
+
def hash
|
172
|
+
[repository, artifact, relative_path, digest].hash
|
173
|
+
end
|
174
|
+
|
175
|
+
# Builds the object from hash
|
176
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
177
|
+
# @return [Object] Returns the model itself
|
178
|
+
def self.build_from_hash(attributes)
|
179
|
+
new.build_from_hash(attributes)
|
180
|
+
end
|
181
|
+
|
182
|
+
# Builds the object from hash
|
183
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
184
|
+
# @return [Object] Returns the model itself
|
185
|
+
def build_from_hash(attributes)
|
186
|
+
return nil unless attributes.is_a?(Hash)
|
187
|
+
self.class.openapi_types.each_pair do |key, type|
|
188
|
+
if type =~ /\AArray<(.*)>/i
|
189
|
+
# check to ensure the input is an array given that the attribute
|
190
|
+
# is documented as an array but the input is not
|
191
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
192
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
193
|
+
end
|
194
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
195
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
196
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
197
|
+
end
|
198
|
+
|
199
|
+
self
|
200
|
+
end
|
201
|
+
|
202
|
+
# Deserializes the data based on type
|
203
|
+
# @param string type Data type
|
204
|
+
# @param string value Value to be deserialized
|
205
|
+
# @return [Object] Deserialized data
|
206
|
+
def _deserialize(type, value)
|
207
|
+
case type.to_sym
|
208
|
+
when :DateTime
|
209
|
+
DateTime.parse(value)
|
210
|
+
when :Date
|
211
|
+
Date.parse(value)
|
212
|
+
when :String
|
213
|
+
value.to_s
|
214
|
+
when :Integer
|
215
|
+
value.to_i
|
216
|
+
when :Float
|
217
|
+
value.to_f
|
218
|
+
when :Boolean
|
219
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
220
|
+
true
|
221
|
+
else
|
222
|
+
false
|
223
|
+
end
|
224
|
+
when :Object
|
225
|
+
# generic object (usually a Hash), return directly
|
226
|
+
value
|
227
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
228
|
+
inner_type = Regexp.last_match[:inner_type]
|
229
|
+
value.map { |v| _deserialize(inner_type, v) }
|
230
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
231
|
+
k_type = Regexp.last_match[:k_type]
|
232
|
+
v_type = Regexp.last_match[:v_type]
|
233
|
+
{}.tap do |hash|
|
234
|
+
value.each do |k, v|
|
235
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
236
|
+
end
|
237
|
+
end
|
238
|
+
else # model
|
239
|
+
PulpOstreeClient.const_get(type).build_from_hash(value)
|
240
|
+
end
|
241
|
+
end
|
242
|
+
|
243
|
+
# Returns the string representation of the object
|
244
|
+
# @return [String] String presentation of the object
|
245
|
+
def to_s
|
246
|
+
to_hash.to_s
|
247
|
+
end
|
248
|
+
|
249
|
+
# to_body is an alias to to_hash (backward compatibility)
|
250
|
+
# @return [Hash] Returns the object in the form of hash
|
251
|
+
def to_body
|
252
|
+
to_hash
|
253
|
+
end
|
254
|
+
|
255
|
+
# Returns the object in the form of hash
|
256
|
+
# @return [Hash] Returns the object in the form of hash
|
257
|
+
def to_hash
|
258
|
+
hash = {}
|
259
|
+
self.class.attribute_map.each_pair do |attr, param|
|
260
|
+
value = self.send(attr)
|
261
|
+
if value.nil?
|
262
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
263
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
264
|
+
end
|
265
|
+
|
266
|
+
hash[param] = _to_hash(value)
|
267
|
+
end
|
268
|
+
hash
|
269
|
+
end
|
270
|
+
|
271
|
+
# Outputs non-array value in the form of hash
|
272
|
+
# For object, use to_hash. Otherwise, just return the value
|
273
|
+
# @param [Object] value Any valid value
|
274
|
+
# @return [Hash] Returns the value in the form of hash
|
275
|
+
def _to_hash(value)
|
276
|
+
if value.is_a?(Array)
|
277
|
+
value.compact.map { |v| _to_hash(v) }
|
278
|
+
elsif value.is_a?(Hash)
|
279
|
+
{}.tap do |hash|
|
280
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
281
|
+
end
|
282
|
+
elsif value.respond_to? :to_hash
|
283
|
+
value.to_hash
|
284
|
+
else
|
285
|
+
value
|
286
|
+
end
|
287
|
+
end
|
288
|
+
end
|
289
|
+
end
|
@@ -20,6 +20,9 @@ module PulpOstreeClient
|
|
20
20
|
# Timestamp of creation.
|
21
21
|
attr_accessor :pulp_created
|
22
22
|
|
23
|
+
# Timestamp of the last time this resource was updated. Note: for immutable resources - like content, repository versions, and publication - pulp_created and pulp_last_updated dates will be the same.
|
24
|
+
attr_accessor :pulp_last_updated
|
25
|
+
|
23
26
|
# Artifact file representing the physical content
|
24
27
|
attr_accessor :artifact
|
25
28
|
|
@@ -32,6 +35,7 @@ module PulpOstreeClient
|
|
32
35
|
{
|
33
36
|
:'pulp_href' => :'pulp_href',
|
34
37
|
:'pulp_created' => :'pulp_created',
|
38
|
+
:'pulp_last_updated' => :'pulp_last_updated',
|
35
39
|
:'artifact' => :'artifact',
|
36
40
|
:'relative_path' => :'relative_path',
|
37
41
|
:'digest' => :'digest'
|
@@ -43,6 +47,7 @@ module PulpOstreeClient
|
|
43
47
|
{
|
44
48
|
:'pulp_href' => :'String',
|
45
49
|
:'pulp_created' => :'DateTime',
|
50
|
+
:'pulp_last_updated' => :'DateTime',
|
46
51
|
:'artifact' => :'String',
|
47
52
|
:'relative_path' => :'String',
|
48
53
|
:'digest' => :'String'
|
@@ -78,6 +83,10 @@ module PulpOstreeClient
|
|
78
83
|
self.pulp_created = attributes[:'pulp_created']
|
79
84
|
end
|
80
85
|
|
86
|
+
if attributes.key?(:'pulp_last_updated')
|
87
|
+
self.pulp_last_updated = attributes[:'pulp_last_updated']
|
88
|
+
end
|
89
|
+
|
81
90
|
if attributes.key?(:'artifact')
|
82
91
|
self.artifact = attributes[:'artifact']
|
83
92
|
end
|
@@ -126,6 +135,7 @@ module PulpOstreeClient
|
|
126
135
|
self.class == o.class &&
|
127
136
|
pulp_href == o.pulp_href &&
|
128
137
|
pulp_created == o.pulp_created &&
|
138
|
+
pulp_last_updated == o.pulp_last_updated &&
|
129
139
|
artifact == o.artifact &&
|
130
140
|
relative_path == o.relative_path &&
|
131
141
|
digest == o.digest
|
@@ -140,7 +150,7 @@ module PulpOstreeClient
|
|
140
150
|
# Calculates hash code according to all attributes.
|
141
151
|
# @return [Integer] Hash code
|
142
152
|
def hash
|
143
|
-
[pulp_href, pulp_created, artifact, relative_path, digest].hash
|
153
|
+
[pulp_href, pulp_created, pulp_last_updated, artifact, relative_path, digest].hash
|
144
154
|
end
|
145
155
|
|
146
156
|
# Builds the object from hash
|
@@ -20,6 +20,9 @@ module PulpOstreeClient
|
|
20
20
|
# Timestamp of creation.
|
21
21
|
attr_accessor :pulp_created
|
22
22
|
|
23
|
+
# Timestamp of the last time this resource was updated. Note: for immutable resources - like content, repository versions, and publication - pulp_created and pulp_last_updated dates will be the same.
|
24
|
+
attr_accessor :pulp_last_updated
|
25
|
+
|
23
26
|
# The base (relative) path component of the published url. Avoid paths that overlap with other distribution base paths (e.g. \"foo\" and \"foo/bar\")
|
24
27
|
attr_accessor :base_path
|
25
28
|
|
@@ -48,6 +51,7 @@ module PulpOstreeClient
|
|
48
51
|
{
|
49
52
|
:'pulp_href' => :'pulp_href',
|
50
53
|
:'pulp_created' => :'pulp_created',
|
54
|
+
:'pulp_last_updated' => :'pulp_last_updated',
|
51
55
|
:'base_path' => :'base_path',
|
52
56
|
:'base_url' => :'base_url',
|
53
57
|
:'content_guard' => :'content_guard',
|
@@ -64,6 +68,7 @@ module PulpOstreeClient
|
|
64
68
|
{
|
65
69
|
:'pulp_href' => :'String',
|
66
70
|
:'pulp_created' => :'DateTime',
|
71
|
+
:'pulp_last_updated' => :'DateTime',
|
67
72
|
:'base_path' => :'String',
|
68
73
|
:'base_url' => :'String',
|
69
74
|
:'content_guard' => :'String',
|
@@ -107,6 +112,10 @@ module PulpOstreeClient
|
|
107
112
|
self.pulp_created = attributes[:'pulp_created']
|
108
113
|
end
|
109
114
|
|
115
|
+
if attributes.key?(:'pulp_last_updated')
|
116
|
+
self.pulp_last_updated = attributes[:'pulp_last_updated']
|
117
|
+
end
|
118
|
+
|
110
119
|
if attributes.key?(:'base_path')
|
111
120
|
self.base_path = attributes[:'base_path']
|
112
121
|
end
|
@@ -174,6 +183,7 @@ module PulpOstreeClient
|
|
174
183
|
self.class == o.class &&
|
175
184
|
pulp_href == o.pulp_href &&
|
176
185
|
pulp_created == o.pulp_created &&
|
186
|
+
pulp_last_updated == o.pulp_last_updated &&
|
177
187
|
base_path == o.base_path &&
|
178
188
|
base_url == o.base_url &&
|
179
189
|
content_guard == o.content_guard &&
|
@@ -193,7 +203,7 @@ module PulpOstreeClient
|
|
193
203
|
# Calculates hash code according to all attributes.
|
194
204
|
# @return [Integer] Hash code
|
195
205
|
def hash
|
196
|
-
[pulp_href, pulp_created, base_path, base_url, content_guard, hidden, pulp_labels, name, repository, repository_version].hash
|
206
|
+
[pulp_href, pulp_created, pulp_last_updated, base_path, base_url, content_guard, hidden, pulp_labels, name, repository, repository_version].hash
|
197
207
|
end
|
198
208
|
|
199
209
|
# Builds the object from hash
|
@@ -20,6 +20,9 @@ module PulpOstreeClient
|
|
20
20
|
# Timestamp of creation.
|
21
21
|
attr_accessor :pulp_created
|
22
22
|
|
23
|
+
# Timestamp of the last time this resource was updated. Note: for immutable resources - like content, repository versions, and publication - pulp_created and pulp_last_updated dates will be the same.
|
24
|
+
attr_accessor :pulp_last_updated
|
25
|
+
|
23
26
|
# Artifact file representing the physical content
|
24
27
|
attr_accessor :artifact
|
25
28
|
|
@@ -36,6 +39,7 @@ module PulpOstreeClient
|
|
36
39
|
{
|
37
40
|
:'pulp_href' => :'pulp_href',
|
38
41
|
:'pulp_created' => :'pulp_created',
|
42
|
+
:'pulp_last_updated' => :'pulp_last_updated',
|
39
43
|
:'artifact' => :'artifact',
|
40
44
|
:'relative_path' => :'relative_path',
|
41
45
|
:'checksum' => :'checksum',
|
@@ -48,6 +52,7 @@ module PulpOstreeClient
|
|
48
52
|
{
|
49
53
|
:'pulp_href' => :'String',
|
50
54
|
:'pulp_created' => :'DateTime',
|
55
|
+
:'pulp_last_updated' => :'DateTime',
|
51
56
|
:'artifact' => :'String',
|
52
57
|
:'relative_path' => :'String',
|
53
58
|
:'checksum' => :'String',
|
@@ -84,6 +89,10 @@ module PulpOstreeClient
|
|
84
89
|
self.pulp_created = attributes[:'pulp_created']
|
85
90
|
end
|
86
91
|
|
92
|
+
if attributes.key?(:'pulp_last_updated')
|
93
|
+
self.pulp_last_updated = attributes[:'pulp_last_updated']
|
94
|
+
end
|
95
|
+
|
87
96
|
if attributes.key?(:'artifact')
|
88
97
|
self.artifact = attributes[:'artifact']
|
89
98
|
end
|
@@ -141,6 +150,7 @@ module PulpOstreeClient
|
|
141
150
|
self.class == o.class &&
|
142
151
|
pulp_href == o.pulp_href &&
|
143
152
|
pulp_created == o.pulp_created &&
|
153
|
+
pulp_last_updated == o.pulp_last_updated &&
|
144
154
|
artifact == o.artifact &&
|
145
155
|
relative_path == o.relative_path &&
|
146
156
|
checksum == o.checksum &&
|
@@ -156,7 +166,7 @@ module PulpOstreeClient
|
|
156
166
|
# Calculates hash code according to all attributes.
|
157
167
|
# @return [Integer] Hash code
|
158
168
|
def hash
|
159
|
-
[pulp_href, pulp_created, artifact, relative_path, checksum, typ].hash
|
169
|
+
[pulp_href, pulp_created, pulp_last_updated, artifact, relative_path, checksum, typ].hash
|
160
170
|
end
|
161
171
|
|
162
172
|
# Builds the object from hash
|
@@ -20,6 +20,9 @@ module PulpOstreeClient
|
|
20
20
|
# Timestamp of creation.
|
21
21
|
attr_accessor :pulp_created
|
22
22
|
|
23
|
+
# Timestamp of the last time this resource was updated. Note: for immutable resources - like content, repository versions, and publication - pulp_created and pulp_last_updated dates will be the same.
|
24
|
+
attr_accessor :pulp_last_updated
|
25
|
+
|
23
26
|
# Artifact file representing the physical content
|
24
27
|
attr_accessor :artifact
|
25
28
|
|
@@ -37,6 +40,7 @@ module PulpOstreeClient
|
|
37
40
|
{
|
38
41
|
:'pulp_href' => :'pulp_href',
|
39
42
|
:'pulp_created' => :'pulp_created',
|
43
|
+
:'pulp_last_updated' => :'pulp_last_updated',
|
40
44
|
:'artifact' => :'artifact',
|
41
45
|
:'relative_path' => :'relative_path',
|
42
46
|
:'commit' => :'commit',
|
@@ -50,6 +54,7 @@ module PulpOstreeClient
|
|
50
54
|
{
|
51
55
|
:'pulp_href' => :'String',
|
52
56
|
:'pulp_created' => :'DateTime',
|
57
|
+
:'pulp_last_updated' => :'DateTime',
|
53
58
|
:'artifact' => :'String',
|
54
59
|
:'relative_path' => :'String',
|
55
60
|
:'commit' => :'String',
|
@@ -87,6 +92,10 @@ module PulpOstreeClient
|
|
87
92
|
self.pulp_created = attributes[:'pulp_created']
|
88
93
|
end
|
89
94
|
|
95
|
+
if attributes.key?(:'pulp_last_updated')
|
96
|
+
self.pulp_last_updated = attributes[:'pulp_last_updated']
|
97
|
+
end
|
98
|
+
|
90
99
|
if attributes.key?(:'artifact')
|
91
100
|
self.artifact = attributes[:'artifact']
|
92
101
|
end
|
@@ -148,6 +157,7 @@ module PulpOstreeClient
|
|
148
157
|
self.class == o.class &&
|
149
158
|
pulp_href == o.pulp_href &&
|
150
159
|
pulp_created == o.pulp_created &&
|
160
|
+
pulp_last_updated == o.pulp_last_updated &&
|
151
161
|
artifact == o.artifact &&
|
152
162
|
relative_path == o.relative_path &&
|
153
163
|
commit == o.commit &&
|
@@ -164,7 +174,7 @@ module PulpOstreeClient
|
|
164
174
|
# Calculates hash code according to all attributes.
|
165
175
|
# @return [Integer] Hash code
|
166
176
|
def hash
|
167
|
-
[pulp_href, pulp_created, artifact, relative_path, commit, checksum, name].hash
|
177
|
+
[pulp_href, pulp_created, pulp_last_updated, artifact, relative_path, commit, checksum, name].hash
|
168
178
|
end
|
169
179
|
|
170
180
|
# Builds the object from hash
|