pulp_container_client 2.15.4 → 2.15.5

Sign up to get free protection for your applications and to get access to all the features.
@@ -15,48 +15,48 @@ require 'date'
15
15
  module PulpContainerClient
16
16
  # Serializer for Container Push Repositories.
17
17
  class ContainerContainerPushRepository
18
- # A unique name for this repository.
19
- attr_accessor :name
20
-
21
- # An optional description.
22
- attr_accessor :description
23
-
24
18
  attr_accessor :pulp_labels
25
19
 
20
+ # Retain X versions of the repository. Default is null which retains all versions.
21
+ attr_accessor :retain_repo_versions
22
+
26
23
  # A reference to an associated signing service.
27
24
  attr_accessor :manifest_signing_service
28
25
 
29
- # Retain X versions of the repository. Default is null which retains all versions.
30
- attr_accessor :retain_repo_versions
26
+ # An optional description.
27
+ attr_accessor :description
28
+
29
+ # A unique name for this repository.
30
+ attr_accessor :name
31
31
 
32
32
  # Attribute mapping from ruby-style variable name to JSON key.
33
33
  def self.attribute_map
34
34
  {
35
- :'name' => :'name',
36
- :'description' => :'description',
37
35
  :'pulp_labels' => :'pulp_labels',
36
+ :'retain_repo_versions' => :'retain_repo_versions',
38
37
  :'manifest_signing_service' => :'manifest_signing_service',
39
- :'retain_repo_versions' => :'retain_repo_versions'
38
+ :'description' => :'description',
39
+ :'name' => :'name'
40
40
  }
41
41
  end
42
42
 
43
43
  # Attribute type mapping.
44
44
  def self.openapi_types
45
45
  {
46
- :'name' => :'String',
47
- :'description' => :'String',
48
46
  :'pulp_labels' => :'Hash<String, String>',
47
+ :'retain_repo_versions' => :'Integer',
49
48
  :'manifest_signing_service' => :'String',
50
- :'retain_repo_versions' => :'Integer'
49
+ :'description' => :'String',
50
+ :'name' => :'String'
51
51
  }
52
52
  end
53
53
 
54
54
  # List of attributes with nullable: true
55
55
  def self.openapi_nullable
56
56
  Set.new([
57
- :'description',
57
+ :'retain_repo_versions',
58
58
  :'manifest_signing_service',
59
- :'retain_repo_versions'
59
+ :'description',
60
60
  ])
61
61
  end
62
62
 
@@ -75,26 +75,26 @@ module PulpContainerClient
75
75
  h[k.to_sym] = v
76
76
  }
77
77
 
78
- if attributes.key?(:'name')
79
- self.name = attributes[:'name']
80
- end
81
-
82
- if attributes.key?(:'description')
83
- self.description = attributes[:'description']
84
- end
85
-
86
78
  if attributes.key?(:'pulp_labels')
87
79
  if (value = attributes[:'pulp_labels']).is_a?(Hash)
88
80
  self.pulp_labels = value
89
81
  end
90
82
  end
91
83
 
84
+ if attributes.key?(:'retain_repo_versions')
85
+ self.retain_repo_versions = attributes[:'retain_repo_versions']
86
+ end
87
+
92
88
  if attributes.key?(:'manifest_signing_service')
93
89
  self.manifest_signing_service = attributes[:'manifest_signing_service']
94
90
  end
95
91
 
96
- if attributes.key?(:'retain_repo_versions')
97
- self.retain_repo_versions = attributes[:'retain_repo_versions']
92
+ if attributes.key?(:'description')
93
+ self.description = attributes[:'description']
94
+ end
95
+
96
+ if attributes.key?(:'name')
97
+ self.name = attributes[:'name']
98
98
  end
99
99
  end
100
100
 
@@ -102,20 +102,20 @@ module PulpContainerClient
102
102
  # @return Array for valid properties with the reasons
103
103
  def list_invalid_properties
104
104
  invalid_properties = Array.new
105
- if @name.nil?
106
- invalid_properties.push('invalid value for "name", name cannot be nil.')
107
- end
108
-
109
- if @name.to_s.length < 1
110
- invalid_properties.push('invalid value for "name", the character length must be great than or equal to 1.')
105
+ if !@retain_repo_versions.nil? && @retain_repo_versions < 1
106
+ invalid_properties.push('invalid value for "retain_repo_versions", must be greater than or equal to 1.')
111
107
  end
112
108
 
113
109
  if !@description.nil? && @description.to_s.length < 1
114
110
  invalid_properties.push('invalid value for "description", the character length must be great than or equal to 1.')
115
111
  end
116
112
 
117
- if !@retain_repo_versions.nil? && @retain_repo_versions < 1
118
- invalid_properties.push('invalid value for "retain_repo_versions", must be greater than or equal to 1.')
113
+ if @name.nil?
114
+ invalid_properties.push('invalid value for "name", name cannot be nil.')
115
+ end
116
+
117
+ if @name.to_s.length < 1
118
+ invalid_properties.push('invalid value for "name", the character length must be great than or equal to 1.')
119
119
  end
120
120
 
121
121
  invalid_properties
@@ -124,25 +124,21 @@ module PulpContainerClient
124
124
  # Check to see if the all the properties in the model are valid
125
125
  # @return true if the model is valid
126
126
  def valid?
127
+ return false if !@retain_repo_versions.nil? && @retain_repo_versions < 1
128
+ return false if !@description.nil? && @description.to_s.length < 1
127
129
  return false if @name.nil?
128
130
  return false if @name.to_s.length < 1
129
- return false if !@description.nil? && @description.to_s.length < 1
130
- return false if !@retain_repo_versions.nil? && @retain_repo_versions < 1
131
131
  true
132
132
  end
133
133
 
134
134
  # Custom attribute writer method with validation
135
- # @param [Object] name Value to be assigned
136
- def name=(name)
137
- if name.nil?
138
- fail ArgumentError, 'name cannot be nil'
139
- end
140
-
141
- if name.to_s.length < 1
142
- fail ArgumentError, 'invalid value for "name", the character length must be great than or equal to 1.'
135
+ # @param [Object] retain_repo_versions Value to be assigned
136
+ def retain_repo_versions=(retain_repo_versions)
137
+ if !retain_repo_versions.nil? && retain_repo_versions < 1
138
+ fail ArgumentError, 'invalid value for "retain_repo_versions", must be greater than or equal to 1.'
143
139
  end
144
140
 
145
- @name = name
141
+ @retain_repo_versions = retain_repo_versions
146
142
  end
147
143
 
148
144
  # Custom attribute writer method with validation
@@ -156,13 +152,17 @@ module PulpContainerClient
156
152
  end
157
153
 
158
154
  # Custom attribute writer method with validation
159
- # @param [Object] retain_repo_versions Value to be assigned
160
- def retain_repo_versions=(retain_repo_versions)
161
- if !retain_repo_versions.nil? && retain_repo_versions < 1
162
- fail ArgumentError, 'invalid value for "retain_repo_versions", must be greater than or equal to 1.'
155
+ # @param [Object] name Value to be assigned
156
+ def name=(name)
157
+ if name.nil?
158
+ fail ArgumentError, 'name cannot be nil'
163
159
  end
164
160
 
165
- @retain_repo_versions = retain_repo_versions
161
+ if name.to_s.length < 1
162
+ fail ArgumentError, 'invalid value for "name", the character length must be great than or equal to 1.'
163
+ end
164
+
165
+ @name = name
166
166
  end
167
167
 
168
168
  # Checks equality by comparing each attribute.
@@ -170,11 +170,11 @@ module PulpContainerClient
170
170
  def ==(o)
171
171
  return true if self.equal?(o)
172
172
  self.class == o.class &&
173
- name == o.name &&
174
- description == o.description &&
175
173
  pulp_labels == o.pulp_labels &&
174
+ retain_repo_versions == o.retain_repo_versions &&
176
175
  manifest_signing_service == o.manifest_signing_service &&
177
- retain_repo_versions == o.retain_repo_versions
176
+ description == o.description &&
177
+ name == o.name
178
178
  end
179
179
 
180
180
  # @see the `==` method
@@ -186,7 +186,7 @@ module PulpContainerClient
186
186
  # Calculates hash code according to all attributes.
187
187
  # @return [Integer] Hash code
188
188
  def hash
189
- [name, description, pulp_labels, manifest_signing_service, retain_repo_versions].hash
189
+ [pulp_labels, retain_repo_versions, manifest_signing_service, description, name].hash
190
190
  end
191
191
 
192
192
  # Builds the object from hash
@@ -15,65 +15,65 @@ require 'date'
15
15
  module PulpContainerClient
16
16
  # Serializer for Container Push Repositories.
17
17
  class ContainerContainerPushRepositoryResponse
18
- # A unique name for this repository.
19
- attr_accessor :name
18
+ attr_accessor :pulp_href
20
19
 
21
20
  # Timestamp of creation.
22
21
  attr_accessor :pulp_created
23
22
 
24
- # An optional description.
25
- attr_accessor :description
26
-
27
23
  attr_accessor :pulp_labels
28
24
 
25
+ # Retain X versions of the repository. Default is null which retains all versions.
26
+ attr_accessor :retain_repo_versions
27
+
28
+ attr_accessor :latest_version_href
29
+
29
30
  # A reference to an associated signing service.
30
31
  attr_accessor :manifest_signing_service
31
32
 
32
- attr_accessor :pulp_href
33
+ # An optional description.
34
+ attr_accessor :description
33
35
 
34
36
  attr_accessor :versions_href
35
37
 
36
- attr_accessor :latest_version_href
37
-
38
- # Retain X versions of the repository. Default is null which retains all versions.
39
- attr_accessor :retain_repo_versions
38
+ # A unique name for this repository.
39
+ attr_accessor :name
40
40
 
41
41
  # Attribute mapping from ruby-style variable name to JSON key.
42
42
  def self.attribute_map
43
43
  {
44
- :'name' => :'name',
44
+ :'pulp_href' => :'pulp_href',
45
45
  :'pulp_created' => :'pulp_created',
46
- :'description' => :'description',
47
46
  :'pulp_labels' => :'pulp_labels',
47
+ :'retain_repo_versions' => :'retain_repo_versions',
48
+ :'latest_version_href' => :'latest_version_href',
48
49
  :'manifest_signing_service' => :'manifest_signing_service',
49
- :'pulp_href' => :'pulp_href',
50
+ :'description' => :'description',
50
51
  :'versions_href' => :'versions_href',
51
- :'latest_version_href' => :'latest_version_href',
52
- :'retain_repo_versions' => :'retain_repo_versions'
52
+ :'name' => :'name'
53
53
  }
54
54
  end
55
55
 
56
56
  # Attribute type mapping.
57
57
  def self.openapi_types
58
58
  {
59
- :'name' => :'String',
59
+ :'pulp_href' => :'String',
60
60
  :'pulp_created' => :'DateTime',
61
- :'description' => :'String',
62
61
  :'pulp_labels' => :'Hash<String, String>',
62
+ :'retain_repo_versions' => :'Integer',
63
+ :'latest_version_href' => :'String',
63
64
  :'manifest_signing_service' => :'String',
64
- :'pulp_href' => :'String',
65
+ :'description' => :'String',
65
66
  :'versions_href' => :'String',
66
- :'latest_version_href' => :'String',
67
- :'retain_repo_versions' => :'Integer'
67
+ :'name' => :'String'
68
68
  }
69
69
  end
70
70
 
71
71
  # List of attributes with nullable: true
72
72
  def self.openapi_nullable
73
73
  Set.new([
74
- :'description',
74
+ :'retain_repo_versions',
75
75
  :'manifest_signing_service',
76
- :'retain_repo_versions'
76
+ :'description',
77
77
  ])
78
78
  end
79
79
 
@@ -92,42 +92,42 @@ module PulpContainerClient
92
92
  h[k.to_sym] = v
93
93
  }
94
94
 
95
- if attributes.key?(:'name')
96
- self.name = attributes[:'name']
95
+ if attributes.key?(:'pulp_href')
96
+ self.pulp_href = attributes[:'pulp_href']
97
97
  end
98
98
 
99
99
  if attributes.key?(:'pulp_created')
100
100
  self.pulp_created = attributes[:'pulp_created']
101
101
  end
102
102
 
103
- if attributes.key?(:'description')
104
- self.description = attributes[:'description']
105
- end
106
-
107
103
  if attributes.key?(:'pulp_labels')
108
104
  if (value = attributes[:'pulp_labels']).is_a?(Hash)
109
105
  self.pulp_labels = value
110
106
  end
111
107
  end
112
108
 
109
+ if attributes.key?(:'retain_repo_versions')
110
+ self.retain_repo_versions = attributes[:'retain_repo_versions']
111
+ end
112
+
113
+ if attributes.key?(:'latest_version_href')
114
+ self.latest_version_href = attributes[:'latest_version_href']
115
+ end
116
+
113
117
  if attributes.key?(:'manifest_signing_service')
114
118
  self.manifest_signing_service = attributes[:'manifest_signing_service']
115
119
  end
116
120
 
117
- if attributes.key?(:'pulp_href')
118
- self.pulp_href = attributes[:'pulp_href']
121
+ if attributes.key?(:'description')
122
+ self.description = attributes[:'description']
119
123
  end
120
124
 
121
125
  if attributes.key?(:'versions_href')
122
126
  self.versions_href = attributes[:'versions_href']
123
127
  end
124
128
 
125
- if attributes.key?(:'latest_version_href')
126
- self.latest_version_href = attributes[:'latest_version_href']
127
- end
128
-
129
- if attributes.key?(:'retain_repo_versions')
130
- self.retain_repo_versions = attributes[:'retain_repo_versions']
129
+ if attributes.key?(:'name')
130
+ self.name = attributes[:'name']
131
131
  end
132
132
  end
133
133
 
@@ -135,22 +135,22 @@ module PulpContainerClient
135
135
  # @return Array for valid properties with the reasons
136
136
  def list_invalid_properties
137
137
  invalid_properties = Array.new
138
- if @name.nil?
139
- invalid_properties.push('invalid value for "name", name cannot be nil.')
140
- end
141
-
142
138
  if !@retain_repo_versions.nil? && @retain_repo_versions < 1
143
139
  invalid_properties.push('invalid value for "retain_repo_versions", must be greater than or equal to 1.')
144
140
  end
145
141
 
142
+ if @name.nil?
143
+ invalid_properties.push('invalid value for "name", name cannot be nil.')
144
+ end
145
+
146
146
  invalid_properties
147
147
  end
148
148
 
149
149
  # Check to see if the all the properties in the model are valid
150
150
  # @return true if the model is valid
151
151
  def valid?
152
- return false if @name.nil?
153
152
  return false if !@retain_repo_versions.nil? && @retain_repo_versions < 1
153
+ return false if @name.nil?
154
154
  true
155
155
  end
156
156
 
@@ -169,15 +169,15 @@ module PulpContainerClient
169
169
  def ==(o)
170
170
  return true if self.equal?(o)
171
171
  self.class == o.class &&
172
- name == o.name &&
172
+ pulp_href == o.pulp_href &&
173
173
  pulp_created == o.pulp_created &&
174
- description == o.description &&
175
174
  pulp_labels == o.pulp_labels &&
175
+ retain_repo_versions == o.retain_repo_versions &&
176
+ latest_version_href == o.latest_version_href &&
176
177
  manifest_signing_service == o.manifest_signing_service &&
177
- pulp_href == o.pulp_href &&
178
+ description == o.description &&
178
179
  versions_href == o.versions_href &&
179
- latest_version_href == o.latest_version_href &&
180
- retain_repo_versions == o.retain_repo_versions
180
+ name == o.name
181
181
  end
182
182
 
183
183
  # @see the `==` method
@@ -189,7 +189,7 @@ module PulpContainerClient
189
189
  # Calculates hash code according to all attributes.
190
190
  # @return [Integer] Hash code
191
191
  def hash
192
- [name, pulp_created, description, pulp_labels, manifest_signing_service, pulp_href, versions_href, latest_version_href, retain_repo_versions].hash
192
+ [pulp_href, pulp_created, pulp_labels, retain_repo_versions, latest_version_href, manifest_signing_service, description, versions_href, name].hash
193
193
  end
194
194
 
195
195
  # Builds the object from hash
@@ -15,12 +15,12 @@ require 'date'
15
15
  module PulpContainerClient
16
16
  # A serializer for ContainerDistribution.
17
17
  class PatchedcontainerContainerDistribution
18
- # A unique name. Ex, `rawhide` and `stable`.
19
- attr_accessor :name
20
-
21
18
  # Whether this distribution should be shown in the content app.
22
19
  attr_accessor :hidden
23
20
 
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\")
22
+ attr_accessor :base_path
23
+
24
24
  # An optional content-guard. If none is specified, a default one will be used.
25
25
  attr_accessor :content_guard
26
26
 
@@ -29,8 +29,8 @@ module PulpContainerClient
29
29
  # The latest RepositoryVersion for this Repository will be served.
30
30
  attr_accessor :repository
31
31
 
32
- # The base (relative) path component of the published url. Avoid paths that overlap with other distribution base paths (e.g. \"foo\" and \"foo/bar\")
33
- attr_accessor :base_path
32
+ # A unique name. Ex, `rawhide` and `stable`.
33
+ attr_accessor :name
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
- :'name' => :'name',
48
47
  :'hidden' => :'hidden',
48
+ :'base_path' => :'base_path',
49
49
  :'content_guard' => :'content_guard',
50
50
  :'pulp_labels' => :'pulp_labels',
51
51
  :'repository' => :'repository',
52
- :'base_path' => :'base_path',
52
+ :'name' => :'name',
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
- :'name' => :'String',
63
62
  :'hidden' => :'Boolean',
63
+ :'base_path' => :'String',
64
64
  :'content_guard' => :'String',
65
65
  :'pulp_labels' => :'Hash<String, String>',
66
66
  :'repository' => :'String',
67
- :'base_path' => :'String',
67
+ :'name' => :'String',
68
68
  :'repository_version' => :'String',
69
69
  :'private' => :'Boolean',
70
70
  :'description' => :'String'
@@ -95,16 +95,16 @@ module PulpContainerClient
95
95
  h[k.to_sym] = v
96
96
  }
97
97
 
98
- if attributes.key?(:'name')
99
- self.name = attributes[:'name']
100
- end
101
-
102
98
  if attributes.key?(:'hidden')
103
99
  self.hidden = attributes[:'hidden']
104
100
  else
105
101
  self.hidden = false
106
102
  end
107
103
 
104
+ if attributes.key?(:'base_path')
105
+ self.base_path = attributes[:'base_path']
106
+ end
107
+
108
108
  if attributes.key?(:'content_guard')
109
109
  self.content_guard = attributes[:'content_guard']
110
110
  end
@@ -119,8 +119,8 @@ module PulpContainerClient
119
119
  self.repository = attributes[:'repository']
120
120
  end
121
121
 
122
- if attributes.key?(:'base_path')
123
- self.base_path = attributes[:'base_path']
122
+ if attributes.key?(:'name')
123
+ self.name = attributes[:'name']
124
124
  end
125
125
 
126
126
  if attributes.key?(:'repository_version')
@@ -140,14 +140,14 @@ module PulpContainerClient
140
140
  # @return Array for valid properties with the reasons
141
141
  def list_invalid_properties
142
142
  invalid_properties = Array.new
143
- if !@name.nil? && @name.to_s.length < 1
144
- invalid_properties.push('invalid value for "name", the character length must be great than or equal to 1.')
145
- end
146
-
147
143
  if !@base_path.nil? && @base_path.to_s.length < 1
148
144
  invalid_properties.push('invalid value for "base_path", the character length must be great than or equal to 1.')
149
145
  end
150
146
 
147
+ if !@name.nil? && @name.to_s.length < 1
148
+ invalid_properties.push('invalid value for "name", the character length must be great than or equal to 1.')
149
+ end
150
+
151
151
  if !@description.nil? && @description.to_s.length < 1
152
152
  invalid_properties.push('invalid value for "description", the character length must be great than or equal to 1.')
153
153
  end
@@ -158,22 +158,12 @@ module PulpContainerClient
158
158
  # Check to see if the all the properties in the model are valid
159
159
  # @return true if the model is valid
160
160
  def valid?
161
- return false if !@name.nil? && @name.to_s.length < 1
162
161
  return false if !@base_path.nil? && @base_path.to_s.length < 1
162
+ return false if !@name.nil? && @name.to_s.length < 1
163
163
  return false if !@description.nil? && @description.to_s.length < 1
164
164
  true
165
165
  end
166
166
 
167
- # Custom attribute writer method with validation
168
- # @param [Object] name Value to be assigned
169
- def name=(name)
170
- if !name.nil? && name.to_s.length < 1
171
- fail ArgumentError, 'invalid value for "name", the character length must be great than or equal to 1.'
172
- end
173
-
174
- @name = name
175
- end
176
-
177
167
  # Custom attribute writer method with validation
178
168
  # @param [Object] base_path Value to be assigned
179
169
  def base_path=(base_path)
@@ -184,6 +174,16 @@ module PulpContainerClient
184
174
  @base_path = base_path
185
175
  end
186
176
 
177
+ # Custom attribute writer method with validation
178
+ # @param [Object] name Value to be assigned
179
+ def name=(name)
180
+ if !name.nil? && name.to_s.length < 1
181
+ fail ArgumentError, 'invalid value for "name", the character length must be great than or equal to 1.'
182
+ end
183
+
184
+ @name = name
185
+ end
186
+
187
187
  # Custom attribute writer method with validation
188
188
  # @param [Object] description Value to be assigned
189
189
  def description=(description)
@@ -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
- name == o.name &&
203
202
  hidden == o.hidden &&
203
+ base_path == o.base_path &&
204
204
  content_guard == o.content_guard &&
205
205
  pulp_labels == o.pulp_labels &&
206
206
  repository == o.repository &&
207
- base_path == o.base_path &&
207
+ name == o.name &&
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
- [name, hidden, content_guard, pulp_labels, repository, base_path, repository_version, private, description].hash
222
+ [hidden, base_path, content_guard, pulp_labels, repository, name, repository_version, private, description].hash
223
223
  end
224
224
 
225
225
  # Builds the object from hash