pulpcore_client 3.16.24 → 3.17.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.
Files changed (136) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +70 -22
  3. data/docs/AccessPoliciesApi.md +53 -0
  4. data/docs/AccessPolicy.md +3 -1
  5. data/docs/AccessPolicyResponse.md +3 -1
  6. data/docs/ContentguardsRbacApi.md +138 -22
  7. data/docs/GroupRole.md +19 -0
  8. data/docs/GroupRoleResponse.md +23 -0
  9. data/docs/GroupsApi.md +248 -20
  10. data/docs/GroupsModelPermissionsApi.md +20 -20
  11. data/docs/GroupsObjectPermissionsApi.md +20 -20
  12. data/docs/GroupsRolesApi.md +255 -0
  13. data/docs/GroupsUsersApi.md +15 -15
  14. data/docs/MyPermissionsResponse.md +17 -0
  15. data/docs/NestedRole.md +21 -0
  16. data/docs/NestedRoleResponse.md +21 -0
  17. data/docs/ObjectRolesResponse.md +17 -0
  18. data/docs/PaginatedGroupRoleResponseList.md +23 -0
  19. data/docs/PaginatedRoleResponseList.md +23 -0
  20. data/docs/PaginatedUserRoleResponseList.md +23 -0
  21. data/docs/PatchedAccessPolicy.md +3 -1
  22. data/docs/PatchedRole.md +21 -0
  23. data/docs/PatchedUser.md +29 -0
  24. data/docs/PermissionResponse.md +1 -1
  25. data/docs/Purge.md +19 -0
  26. data/docs/Role.md +21 -0
  27. data/docs/RoleResponse.md +27 -0
  28. data/docs/RolesApi.md +363 -0
  29. data/docs/StatesEnum.md +16 -0
  30. data/docs/TasksApi.md +282 -0
  31. data/docs/User.md +29 -0
  32. data/docs/UserGroup.md +17 -0
  33. data/docs/UserResponse.md +3 -3
  34. data/docs/UserRole.md +19 -0
  35. data/docs/UserRoleResponse.md +23 -0
  36. data/docs/UsersApi.md +219 -0
  37. data/docs/UsersRolesApi.md +255 -0
  38. data/docs/WorkerResponse.md +3 -3
  39. data/git_push.sh +58 -0
  40. data/lib/pulpcore_client/api/access_policies_api.rb +60 -0
  41. data/lib/pulpcore_client/api/artifacts_api.rb +24 -0
  42. data/lib/pulpcore_client/api/contentguards_rbac_api.rb +168 -40
  43. data/lib/pulpcore_client/api/groups_api.rb +304 -36
  44. data/lib/pulpcore_client/api/groups_model_permissions_api.rb +36 -36
  45. data/lib/pulpcore_client/api/groups_object_permissions_api.rb +36 -36
  46. data/lib/pulpcore_client/api/groups_roles_api.rb +315 -0
  47. data/lib/pulpcore_client/api/groups_users_api.rb +27 -27
  48. data/lib/pulpcore_client/api/roles_api.rb +443 -0
  49. data/lib/pulpcore_client/api/tasks_api.rb +332 -0
  50. data/lib/pulpcore_client/api/uploads_api.rb +4 -0
  51. data/lib/pulpcore_client/api/users_api.rb +264 -0
  52. data/lib/pulpcore_client/api/users_roles_api.rb +315 -0
  53. data/lib/pulpcore_client/api_client.rb +5 -2
  54. data/lib/pulpcore_client/configuration.rb +0 -1
  55. data/lib/pulpcore_client/models/access_policy.rb +19 -2
  56. data/lib/pulpcore_client/models/access_policy_response.rb +19 -2
  57. data/lib/pulpcore_client/models/artifact.rb +90 -0
  58. data/lib/pulpcore_client/models/filesystem_exporter.rb +38 -0
  59. data/lib/pulpcore_client/models/group.rb +9 -0
  60. data/lib/pulpcore_client/models/group_role.rb +238 -0
  61. data/lib/pulpcore_client/models/group_role_response.rb +242 -0
  62. data/lib/pulpcore_client/models/group_user.rb +9 -0
  63. data/lib/pulpcore_client/models/{rbac_content_guard_permission.rb → my_permissions_response.rb} +16 -22
  64. data/lib/pulpcore_client/models/nested_role.rb +234 -0
  65. data/lib/pulpcore_client/models/nested_role_response.rb +234 -0
  66. data/lib/pulpcore_client/models/object_roles_response.rb +213 -0
  67. data/lib/pulpcore_client/models/paginated_group_role_response_list.rb +237 -0
  68. data/lib/pulpcore_client/models/paginated_role_response_list.rb +237 -0
  69. data/lib/pulpcore_client/models/paginated_user_role_response_list.rb +237 -0
  70. data/lib/pulpcore_client/models/patched_access_policy.rb +14 -2
  71. data/lib/pulpcore_client/models/patched_filesystem_exporter.rb +30 -0
  72. data/lib/pulpcore_client/models/patched_group.rb +9 -0
  73. data/lib/pulpcore_client/models/patched_pulp_exporter.rb +30 -0
  74. data/lib/pulpcore_client/models/patched_pulp_importer.rb +15 -0
  75. data/lib/pulpcore_client/models/patched_rbac_content_guard.rb +30 -0
  76. data/lib/pulpcore_client/models/patched_role.rb +261 -0
  77. data/lib/pulpcore_client/models/patched_task_cancel.rb +15 -0
  78. data/lib/pulpcore_client/models/patched_user.rb +342 -0
  79. data/lib/pulpcore_client/models/permission_response.rb +1 -1
  80. data/lib/pulpcore_client/models/pulp_export.rb +15 -0
  81. data/lib/pulpcore_client/models/pulp_exporter.rb +38 -0
  82. data/lib/pulpcore_client/models/pulp_import.rb +30 -0
  83. data/lib/pulpcore_client/models/pulp_import_check.rb +45 -0
  84. data/lib/pulpcore_client/models/pulp_importer.rb +19 -0
  85. data/lib/pulpcore_client/models/purge.rb +219 -0
  86. data/lib/pulpcore_client/models/rbac_content_guard.rb +34 -0
  87. data/lib/pulpcore_client/models/role.rb +275 -0
  88. data/lib/pulpcore_client/models/role_response.rb +270 -0
  89. data/lib/pulpcore_client/models/states_enum.rb +38 -0
  90. data/lib/pulpcore_client/models/upload_chunk.rb +15 -0
  91. data/lib/pulpcore_client/models/upload_commit.rb +19 -0
  92. data/lib/pulpcore_client/models/user.rb +351 -0
  93. data/lib/pulpcore_client/models/user_group.rb +241 -0
  94. data/lib/pulpcore_client/models/user_response.rb +6 -29
  95. data/lib/pulpcore_client/models/user_role.rb +238 -0
  96. data/lib/pulpcore_client/models/user_role_response.rb +242 -0
  97. data/lib/pulpcore_client/models/worker_response.rb +10 -10
  98. data/lib/pulpcore_client/version.rb +1 -1
  99. data/lib/pulpcore_client.rb +22 -1
  100. data/pulpcore_client.gemspec +3 -3
  101. data/spec/api/access_policies_api_spec.rb +11 -0
  102. data/spec/api/contentguards_rbac_api_spec.rb +36 -12
  103. data/spec/api/groups_api_spec.rb +54 -4
  104. data/spec/api/groups_model_permissions_api_spec.rb +4 -4
  105. data/spec/api/groups_object_permissions_api_spec.rb +4 -4
  106. data/spec/api/groups_roles_api_spec.rb +97 -0
  107. data/spec/api/groups_users_api_spec.rb +3 -3
  108. data/spec/api/roles_api_spec.rb +121 -0
  109. data/spec/api/tasks_api_spec.rb +62 -0
  110. data/spec/api/users_api_spec.rb +50 -0
  111. data/spec/api/users_roles_api_spec.rb +97 -0
  112. data/spec/models/access_policy_response_spec.rb +6 -0
  113. data/spec/models/access_policy_spec.rb +6 -0
  114. data/spec/models/group_role_response_spec.rb +59 -0
  115. data/spec/models/{rbac_content_guard_permission_spec.rb → group_role_spec.rb} +8 -8
  116. data/spec/models/my_permissions_response_spec.rb +41 -0
  117. data/spec/models/nested_role_response_spec.rb +53 -0
  118. data/spec/models/nested_role_spec.rb +53 -0
  119. data/spec/models/object_roles_response_spec.rb +41 -0
  120. data/spec/models/paginated_group_role_response_list_spec.rb +59 -0
  121. data/spec/models/paginated_role_response_list_spec.rb +59 -0
  122. data/spec/models/paginated_user_role_response_list_spec.rb +59 -0
  123. data/spec/models/patched_access_policy_spec.rb +6 -0
  124. data/spec/models/patched_role_spec.rb +53 -0
  125. data/spec/models/patched_user_spec.rb +77 -0
  126. data/spec/models/purge_spec.rb +47 -0
  127. data/spec/models/role_response_spec.rb +71 -0
  128. data/spec/models/role_spec.rb +53 -0
  129. data/spec/models/states_enum_spec.rb +35 -0
  130. data/spec/models/user_group_spec.rb +41 -0
  131. data/spec/models/user_role_response_spec.rb +59 -0
  132. data/spec/models/user_role_spec.rb +47 -0
  133. data/spec/models/user_spec.rb +77 -0
  134. data/spec/models/worker_response_spec.rb +2 -2
  135. metadata +190 -111
  136. data/docs/RBACContentGuardPermission.md +0 -19
@@ -0,0 +1,342 @@
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 User.
17
+ class PatchedUser
18
+ # Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.
19
+ attr_accessor :username
20
+
21
+ # Users password. Set to ``null`` to disable password authentication.
22
+ attr_accessor :password
23
+
24
+ # First name
25
+ attr_accessor :first_name
26
+
27
+ # Last name
28
+ attr_accessor :last_name
29
+
30
+ # Email address
31
+ attr_accessor :email
32
+
33
+ # Designates whether the user can log into this admin site.
34
+ attr_accessor :is_staff
35
+
36
+ # Designates whether this user should be treated as active.
37
+ attr_accessor :is_active
38
+
39
+ # Attribute mapping from ruby-style variable name to JSON key.
40
+ def self.attribute_map
41
+ {
42
+ :'username' => :'username',
43
+ :'password' => :'password',
44
+ :'first_name' => :'first_name',
45
+ :'last_name' => :'last_name',
46
+ :'email' => :'email',
47
+ :'is_staff' => :'is_staff',
48
+ :'is_active' => :'is_active'
49
+ }
50
+ end
51
+
52
+ # Attribute type mapping.
53
+ def self.openapi_types
54
+ {
55
+ :'username' => :'String',
56
+ :'password' => :'String',
57
+ :'first_name' => :'String',
58
+ :'last_name' => :'String',
59
+ :'email' => :'String',
60
+ :'is_staff' => :'Boolean',
61
+ :'is_active' => :'Boolean'
62
+ }
63
+ end
64
+
65
+ # List of attributes with nullable: true
66
+ def self.openapi_nullable
67
+ Set.new([
68
+ :'password',
69
+ ])
70
+ end
71
+
72
+ # Initializes the object
73
+ # @param [Hash] attributes Model attributes in the form of hash
74
+ def initialize(attributes = {})
75
+ if (!attributes.is_a?(Hash))
76
+ fail ArgumentError, "The input argument (attributes) must be a hash in `PulpcoreClient::PatchedUser` initialize method"
77
+ end
78
+
79
+ # check to see if the attribute exists and convert string to symbol for hash key
80
+ attributes = attributes.each_with_object({}) { |(k, v), h|
81
+ if (!self.class.attribute_map.key?(k.to_sym))
82
+ fail ArgumentError, "`#{k}` is not a valid attribute in `PulpcoreClient::PatchedUser`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
83
+ end
84
+ h[k.to_sym] = v
85
+ }
86
+
87
+ if attributes.key?(:'username')
88
+ self.username = attributes[:'username']
89
+ end
90
+
91
+ if attributes.key?(:'password')
92
+ self.password = attributes[:'password']
93
+ end
94
+
95
+ if attributes.key?(:'first_name')
96
+ self.first_name = attributes[:'first_name']
97
+ end
98
+
99
+ if attributes.key?(:'last_name')
100
+ self.last_name = attributes[:'last_name']
101
+ end
102
+
103
+ if attributes.key?(:'email')
104
+ self.email = attributes[:'email']
105
+ end
106
+
107
+ if attributes.key?(:'is_staff')
108
+ self.is_staff = attributes[:'is_staff']
109
+ else
110
+ self.is_staff = false
111
+ end
112
+
113
+ if attributes.key?(:'is_active')
114
+ self.is_active = attributes[:'is_active']
115
+ else
116
+ self.is_active = true
117
+ end
118
+ end
119
+
120
+ # Show invalid properties with the reasons. Usually used together with valid?
121
+ # @return Array for valid properties with the reasons
122
+ def list_invalid_properties
123
+ invalid_properties = Array.new
124
+ if !@username.nil? && @username.to_s.length > 150
125
+ invalid_properties.push('invalid value for "username", the character length must be smaller than or equal to 150.')
126
+ end
127
+
128
+ if !@username.nil? && @username.to_s.length < 1
129
+ invalid_properties.push('invalid value for "username", the character length must be great than or equal to 1.')
130
+ end
131
+
132
+ if !@password.nil? && @password.to_s.length < 1
133
+ invalid_properties.push('invalid value for "password", the character length must be great than or equal to 1.')
134
+ end
135
+
136
+ if !@first_name.nil? && @first_name.to_s.length > 150
137
+ invalid_properties.push('invalid value for "first_name", the character length must be smaller than or equal to 150.')
138
+ end
139
+
140
+ if !@last_name.nil? && @last_name.to_s.length > 150
141
+ invalid_properties.push('invalid value for "last_name", the character length must be smaller than or equal to 150.')
142
+ end
143
+
144
+ invalid_properties
145
+ end
146
+
147
+ # Check to see if the all the properties in the model are valid
148
+ # @return true if the model is valid
149
+ def valid?
150
+ return false if !@username.nil? && @username.to_s.length > 150
151
+ return false if !@username.nil? && @username.to_s.length < 1
152
+ return false if !@password.nil? && @password.to_s.length < 1
153
+ return false if !@first_name.nil? && @first_name.to_s.length > 150
154
+ return false if !@last_name.nil? && @last_name.to_s.length > 150
155
+ true
156
+ end
157
+
158
+ # Custom attribute writer method with validation
159
+ # @param [Object] username Value to be assigned
160
+ def username=(username)
161
+ if !username.nil? && username.to_s.length > 150
162
+ fail ArgumentError, 'invalid value for "username", the character length must be smaller than or equal to 150.'
163
+ end
164
+
165
+ if !username.nil? && username.to_s.length < 1
166
+ fail ArgumentError, 'invalid value for "username", the character length must be great than or equal to 1.'
167
+ end
168
+
169
+ @username = username
170
+ end
171
+
172
+ # Custom attribute writer method with validation
173
+ # @param [Object] password Value to be assigned
174
+ def password=(password)
175
+ if !password.nil? && password.to_s.length < 1
176
+ fail ArgumentError, 'invalid value for "password", the character length must be great than or equal to 1.'
177
+ end
178
+
179
+ @password = password
180
+ end
181
+
182
+ # Custom attribute writer method with validation
183
+ # @param [Object] first_name Value to be assigned
184
+ def first_name=(first_name)
185
+ if !first_name.nil? && first_name.to_s.length > 150
186
+ fail ArgumentError, 'invalid value for "first_name", the character length must be smaller than or equal to 150.'
187
+ end
188
+
189
+ @first_name = first_name
190
+ end
191
+
192
+ # Custom attribute writer method with validation
193
+ # @param [Object] last_name Value to be assigned
194
+ def last_name=(last_name)
195
+ if !last_name.nil? && last_name.to_s.length > 150
196
+ fail ArgumentError, 'invalid value for "last_name", the character length must be smaller than or equal to 150.'
197
+ end
198
+
199
+ @last_name = last_name
200
+ end
201
+
202
+ # Checks equality by comparing each attribute.
203
+ # @param [Object] Object to be compared
204
+ def ==(o)
205
+ return true if self.equal?(o)
206
+ self.class == o.class &&
207
+ username == o.username &&
208
+ password == o.password &&
209
+ first_name == o.first_name &&
210
+ last_name == o.last_name &&
211
+ email == o.email &&
212
+ is_staff == o.is_staff &&
213
+ is_active == o.is_active
214
+ end
215
+
216
+ # @see the `==` method
217
+ # @param [Object] Object to be compared
218
+ def eql?(o)
219
+ self == o
220
+ end
221
+
222
+ # Calculates hash code according to all attributes.
223
+ # @return [Integer] Hash code
224
+ def hash
225
+ [username, password, first_name, last_name, email, is_staff, is_active].hash
226
+ end
227
+
228
+ # Builds the object from hash
229
+ # @param [Hash] attributes Model attributes in the form of hash
230
+ # @return [Object] Returns the model itself
231
+ def self.build_from_hash(attributes)
232
+ new.build_from_hash(attributes)
233
+ end
234
+
235
+ # Builds the object from hash
236
+ # @param [Hash] attributes Model attributes in the form of hash
237
+ # @return [Object] Returns the model itself
238
+ def build_from_hash(attributes)
239
+ return nil unless attributes.is_a?(Hash)
240
+ self.class.openapi_types.each_pair do |key, type|
241
+ if type =~ /\AArray<(.*)>/i
242
+ # check to ensure the input is an array given that the attribute
243
+ # is documented as an array but the input is not
244
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
245
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
246
+ end
247
+ elsif !attributes[self.class.attribute_map[key]].nil?
248
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
249
+ end # or else data not found in attributes(hash), not an issue as the data can be optional
250
+ end
251
+
252
+ self
253
+ end
254
+
255
+ # Deserializes the data based on type
256
+ # @param string type Data type
257
+ # @param string value Value to be deserialized
258
+ # @return [Object] Deserialized data
259
+ def _deserialize(type, value)
260
+ case type.to_sym
261
+ when :DateTime
262
+ DateTime.parse(value)
263
+ when :Date
264
+ Date.parse(value)
265
+ when :String
266
+ value.to_s
267
+ when :Integer
268
+ value.to_i
269
+ when :Float
270
+ value.to_f
271
+ when :Boolean
272
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
273
+ true
274
+ else
275
+ false
276
+ end
277
+ when :Object
278
+ # generic object (usually a Hash), return directly
279
+ value
280
+ when /\AArray<(?<inner_type>.+)>\z/
281
+ inner_type = Regexp.last_match[:inner_type]
282
+ value.map { |v| _deserialize(inner_type, v) }
283
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
284
+ k_type = Regexp.last_match[:k_type]
285
+ v_type = Regexp.last_match[:v_type]
286
+ {}.tap do |hash|
287
+ value.each do |k, v|
288
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
289
+ end
290
+ end
291
+ else # model
292
+ PulpcoreClient.const_get(type).build_from_hash(value)
293
+ end
294
+ end
295
+
296
+ # Returns the string representation of the object
297
+ # @return [String] String presentation of the object
298
+ def to_s
299
+ to_hash.to_s
300
+ end
301
+
302
+ # to_body is an alias to to_hash (backward compatibility)
303
+ # @return [Hash] Returns the object in the form of hash
304
+ def to_body
305
+ to_hash
306
+ end
307
+
308
+ # Returns the object in the form of hash
309
+ # @return [Hash] Returns the object in the form of hash
310
+ def to_hash
311
+ hash = {}
312
+ self.class.attribute_map.each_pair do |attr, param|
313
+ value = self.send(attr)
314
+ if value.nil?
315
+ is_nullable = self.class.openapi_nullable.include?(attr)
316
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
317
+ end
318
+
319
+ hash[param] = _to_hash(value)
320
+ end
321
+ hash
322
+ end
323
+
324
+ # Outputs non-array value in the form of hash
325
+ # For object, use to_hash. Otherwise, just return the value
326
+ # @param [Object] value Any valid value
327
+ # @return [Hash] Returns the value in the form of hash
328
+ def _to_hash(value)
329
+ if value.is_a?(Array)
330
+ value.compact.map { |v| _to_hash(v) }
331
+ elsif value.is_a?(Hash)
332
+ {}.tap do |hash|
333
+ value.each { |k, v| hash[k] = _to_hash(v) }
334
+ end
335
+ elsif value.respond_to? :to_hash
336
+ value.to_hash
337
+ else
338
+ value
339
+ end
340
+ end
341
+ end
342
+ end
@@ -21,7 +21,7 @@ module PulpcoreClient
21
21
 
22
22
  attr_accessor :permission
23
23
 
24
- # Content object.
24
+ # pulp_href of the object the permission is to be asserted on.
25
25
  attr_accessor :obj
26
26
 
27
27
  # Attribute mapping from ruby-style variable name to JSON key.
@@ -116,15 +116,30 @@ module PulpcoreClient
116
116
  # @return Array for valid properties with the reasons
117
117
  def list_invalid_properties
118
118
  invalid_properties = Array.new
119
+ if !@chunk_size.nil? && @chunk_size.to_s.length < 1
120
+ invalid_properties.push('invalid value for "chunk_size", the character length must be great than or equal to 1.')
121
+ end
122
+
119
123
  invalid_properties
120
124
  end
121
125
 
122
126
  # Check to see if the all the properties in the model are valid
123
127
  # @return true if the model is valid
124
128
  def valid?
129
+ return false if !@chunk_size.nil? && @chunk_size.to_s.length < 1
125
130
  true
126
131
  end
127
132
 
133
+ # Custom attribute writer method with validation
134
+ # @param [Object] chunk_size Value to be assigned
135
+ def chunk_size=(chunk_size)
136
+ if !chunk_size.nil? && chunk_size.to_s.length < 1
137
+ fail ArgumentError, 'invalid value for "chunk_size", the character length must be great than or equal to 1.'
138
+ end
139
+
140
+ @chunk_size = chunk_size
141
+ end
142
+
128
143
  # Checks equality by comparing each attribute.
129
144
  # @param [Object] Object to be compared
130
145
  def ==(o)
@@ -95,10 +95,18 @@ module PulpcoreClient
95
95
  invalid_properties.push('invalid value for "name", name cannot be nil.')
96
96
  end
97
97
 
98
+ if @name.to_s.length < 1
99
+ invalid_properties.push('invalid value for "name", the character length must be great than or equal to 1.')
100
+ end
101
+
98
102
  if @path.nil?
99
103
  invalid_properties.push('invalid value for "path", path cannot be nil.')
100
104
  end
101
105
 
106
+ if @path.to_s.length < 1
107
+ invalid_properties.push('invalid value for "path", the character length must be great than or equal to 1.')
108
+ end
109
+
102
110
  if @repositories.nil?
103
111
  invalid_properties.push('invalid value for "repositories", repositories cannot be nil.')
104
112
  end
@@ -110,11 +118,41 @@ module PulpcoreClient
110
118
  # @return true if the model is valid
111
119
  def valid?
112
120
  return false if @name.nil?
121
+ return false if @name.to_s.length < 1
113
122
  return false if @path.nil?
123
+ return false if @path.to_s.length < 1
114
124
  return false if @repositories.nil?
115
125
  true
116
126
  end
117
127
 
128
+ # Custom attribute writer method with validation
129
+ # @param [Object] name Value to be assigned
130
+ def name=(name)
131
+ if name.nil?
132
+ fail ArgumentError, 'name cannot be nil'
133
+ end
134
+
135
+ if name.to_s.length < 1
136
+ fail ArgumentError, 'invalid value for "name", the character length must be great than or equal to 1.'
137
+ end
138
+
139
+ @name = name
140
+ end
141
+
142
+ # Custom attribute writer method with validation
143
+ # @param [Object] path Value to be assigned
144
+ def path=(path)
145
+ if path.nil?
146
+ fail ArgumentError, 'path cannot be nil'
147
+ end
148
+
149
+ if path.to_s.length < 1
150
+ fail ArgumentError, 'invalid value for "path", the character length must be great than or equal to 1.'
151
+ end
152
+
153
+ @path = path
154
+ end
155
+
118
156
  # Checks equality by comparing each attribute.
119
157
  # @param [Object] Object to be compared
120
158
  def ==(o)
@@ -71,15 +71,45 @@ module PulpcoreClient
71
71
  # @return Array for valid properties with the reasons
72
72
  def list_invalid_properties
73
73
  invalid_properties = Array.new
74
+ if !@path.nil? && @path.to_s.length < 1
75
+ invalid_properties.push('invalid value for "path", the character length must be great than or equal to 1.')
76
+ end
77
+
78
+ if !@toc.nil? && @toc.to_s.length < 1
79
+ invalid_properties.push('invalid value for "toc", the character length must be great than or equal to 1.')
80
+ end
81
+
74
82
  invalid_properties
75
83
  end
76
84
 
77
85
  # Check to see if the all the properties in the model are valid
78
86
  # @return true if the model is valid
79
87
  def valid?
88
+ return false if !@path.nil? && @path.to_s.length < 1
89
+ return false if !@toc.nil? && @toc.to_s.length < 1
80
90
  true
81
91
  end
82
92
 
93
+ # Custom attribute writer method with validation
94
+ # @param [Object] path Value to be assigned
95
+ def path=(path)
96
+ if !path.nil? && path.to_s.length < 1
97
+ fail ArgumentError, 'invalid value for "path", the character length must be great than or equal to 1.'
98
+ end
99
+
100
+ @path = path
101
+ end
102
+
103
+ # Custom attribute writer method with validation
104
+ # @param [Object] toc Value to be assigned
105
+ def toc=(toc)
106
+ if !toc.nil? && toc.to_s.length < 1
107
+ fail ArgumentError, 'invalid value for "toc", the character length must be great than or equal to 1.'
108
+ end
109
+
110
+ @toc = toc
111
+ end
112
+
83
113
  # Checks equality by comparing each attribute.
84
114
  # @param [Object] Object to be compared
85
115
  def ==(o)
@@ -80,15 +80,60 @@ module PulpcoreClient
80
80
  # @return Array for valid properties with the reasons
81
81
  def list_invalid_properties
82
82
  invalid_properties = Array.new
83
+ if !@path.nil? && @path.to_s.length < 1
84
+ invalid_properties.push('invalid value for "path", the character length must be great than or equal to 1.')
85
+ end
86
+
87
+ if !@toc.nil? && @toc.to_s.length < 1
88
+ invalid_properties.push('invalid value for "toc", the character length must be great than or equal to 1.')
89
+ end
90
+
91
+ if !@repo_mapping.nil? && @repo_mapping.to_s.length < 1
92
+ invalid_properties.push('invalid value for "repo_mapping", the character length must be great than or equal to 1.')
93
+ end
94
+
83
95
  invalid_properties
84
96
  end
85
97
 
86
98
  # Check to see if the all the properties in the model are valid
87
99
  # @return true if the model is valid
88
100
  def valid?
101
+ return false if !@path.nil? && @path.to_s.length < 1
102
+ return false if !@toc.nil? && @toc.to_s.length < 1
103
+ return false if !@repo_mapping.nil? && @repo_mapping.to_s.length < 1
89
104
  true
90
105
  end
91
106
 
107
+ # Custom attribute writer method with validation
108
+ # @param [Object] path Value to be assigned
109
+ def path=(path)
110
+ if !path.nil? && path.to_s.length < 1
111
+ fail ArgumentError, 'invalid value for "path", the character length must be great than or equal to 1.'
112
+ end
113
+
114
+ @path = path
115
+ end
116
+
117
+ # Custom attribute writer method with validation
118
+ # @param [Object] toc Value to be assigned
119
+ def toc=(toc)
120
+ if !toc.nil? && toc.to_s.length < 1
121
+ fail ArgumentError, 'invalid value for "toc", the character length must be great than or equal to 1.'
122
+ end
123
+
124
+ @toc = toc
125
+ end
126
+
127
+ # Custom attribute writer method with validation
128
+ # @param [Object] repo_mapping Value to be assigned
129
+ def repo_mapping=(repo_mapping)
130
+ if !repo_mapping.nil? && repo_mapping.to_s.length < 1
131
+ fail ArgumentError, 'invalid value for "repo_mapping", the character length must be great than or equal to 1.'
132
+ end
133
+
134
+ @repo_mapping = repo_mapping
135
+ end
136
+
92
137
  # Checks equality by comparing each attribute.
93
138
  # @param [Object] Object to be compared
94
139
  def ==(o)
@@ -77,6 +77,10 @@ module PulpcoreClient
77
77
  invalid_properties.push('invalid value for "name", name cannot be nil.')
78
78
  end
79
79
 
80
+ if @name.to_s.length < 1
81
+ invalid_properties.push('invalid value for "name", the character length must be great than or equal to 1.')
82
+ end
83
+
80
84
  invalid_properties
81
85
  end
82
86
 
@@ -84,9 +88,24 @@ module PulpcoreClient
84
88
  # @return true if the model is valid
85
89
  def valid?
86
90
  return false if @name.nil?
91
+ return false if @name.to_s.length < 1
87
92
  true
88
93
  end
89
94
 
95
+ # Custom attribute writer method with validation
96
+ # @param [Object] name Value to be assigned
97
+ def name=(name)
98
+ if name.nil?
99
+ fail ArgumentError, 'name cannot be nil'
100
+ end
101
+
102
+ if name.to_s.length < 1
103
+ fail ArgumentError, 'invalid value for "name", the character length must be great than or equal to 1.'
104
+ end
105
+
106
+ @name = name
107
+ end
108
+
90
109
  # Checks equality by comparing each attribute.
91
110
  # @param [Object] Object to be compared
92
111
  def ==(o)