pulp_rpm_client 3.27.2 → 3.28.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (322) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +10 -9
  3. data/docs/AcsRpmApi.md +343 -156
  4. data/docs/AddonResponse.md +16 -15
  5. data/docs/ArtifactResponse.md +30 -29
  6. data/docs/AsyncOperationResponse.md +8 -7
  7. data/docs/ChecksumResponse.md +10 -9
  8. data/docs/CompressionTypeEnum.md +4 -5
  9. data/docs/ContentAdvisoriesApi.md +125 -75
  10. data/docs/ContentDistributionTreesApi.md +79 -46
  11. data/docs/ContentModulemdDefaultsApi.md +114 -64
  12. data/docs/ContentModulemdObsoletesApi.md +107 -57
  13. data/docs/ContentModulemdsApi.md +123 -73
  14. data/docs/ContentPackagecategoriesApi.md +79 -46
  15. data/docs/ContentPackageenvironmentsApi.md +79 -46
  16. data/docs/ContentPackagegroupsApi.md +79 -46
  17. data/docs/ContentPackagelangpacksApi.md +79 -46
  18. data/docs/ContentPackagesApi.md +148 -98
  19. data/docs/ContentRepoMetadataFilesApi.md +79 -46
  20. data/docs/ContentSummaryResponse.md +12 -11
  21. data/docs/Copy.md +10 -9
  22. data/docs/DistributionsRpmApi.md +385 -182
  23. data/docs/ImageResponse.md +14 -13
  24. data/docs/MyPermissionsResponse.md +8 -7
  25. data/docs/NestedRole.md +12 -11
  26. data/docs/NestedRoleResponse.md +12 -11
  27. data/docs/ObjectRolesResponse.md +8 -7
  28. data/docs/PackageChecksumTypeEnum.md +4 -5
  29. data/docs/PaginatedRepositoryVersionResponseList.md +14 -13
  30. data/docs/PaginatedrpmDistributionTreeResponseList.md +14 -13
  31. data/docs/PaginatedrpmModulemdDefaultsResponseList.md +14 -13
  32. data/docs/PaginatedrpmModulemdObsoleteResponseList.md +14 -13
  33. data/docs/PaginatedrpmModulemdResponseList.md +14 -13
  34. data/docs/PaginatedrpmPackageCategoryResponseList.md +14 -13
  35. data/docs/PaginatedrpmPackageEnvironmentResponseList.md +14 -13
  36. data/docs/PaginatedrpmPackageGroupResponseList.md +14 -13
  37. data/docs/PaginatedrpmPackageLangpacksResponseList.md +14 -13
  38. data/docs/PaginatedrpmPackageResponseList.md +14 -13
  39. data/docs/PaginatedrpmRepoMetadataFileResponseList.md +14 -13
  40. data/docs/PaginatedrpmRpmAlternateContentSourceResponseList.md +14 -13
  41. data/docs/PaginatedrpmRpmDistributionResponseList.md +14 -13
  42. data/docs/PaginatedrpmRpmPublicationResponseList.md +14 -13
  43. data/docs/PaginatedrpmRpmRemoteResponseList.md +14 -13
  44. data/docs/PaginatedrpmRpmRepositoryResponseList.md +14 -13
  45. data/docs/PaginatedrpmUlnRemoteResponseList.md +14 -13
  46. data/docs/PaginatedrpmUpdateRecordResponseList.md +14 -13
  47. data/docs/PatchedrpmRpmAlternateContentSource.md +14 -13
  48. data/docs/PatchedrpmRpmDistribution.md +22 -21
  49. data/docs/PatchedrpmRpmRemote.md +50 -49
  50. data/docs/PatchedrpmRpmRepository.md +40 -39
  51. data/docs/PatchedrpmUlnRemote.md +50 -49
  52. data/docs/PolicyEnum.md +4 -5
  53. data/docs/PrunePackages.md +12 -11
  54. data/docs/PublicationsRpmApi.md +267 -130
  55. data/docs/RemotesRpmApi.md +389 -184
  56. data/docs/RemotesUlnApi.md +389 -184
  57. data/docs/Repair.md +8 -7
  58. data/docs/RepositoriesRpmApi.md +444 -207
  59. data/docs/RepositoriesRpmVersionsApi.md +152 -82
  60. data/docs/RepositoryAddRemoveContent.md +12 -11
  61. data/docs/RepositoryVersionResponse.md +22 -21
  62. data/docs/RpmCompsApi.md +32 -16
  63. data/docs/RpmCopyApi.md +30 -14
  64. data/docs/RpmDistributionTreeResponse.md +46 -43
  65. data/docs/RpmModulemd.md +32 -31
  66. data/docs/RpmModulemdDefaults.md +16 -15
  67. data/docs/RpmModulemdDefaultsResponse.md +20 -19
  68. data/docs/RpmModulemdObsolete.md +28 -27
  69. data/docs/RpmModulemdObsoleteResponse.md +32 -31
  70. data/docs/RpmModulemdResponse.md +36 -35
  71. data/docs/RpmPackageCategoryResponse.md +30 -29
  72. data/docs/RpmPackageEnvironmentResponse.md +32 -31
  73. data/docs/RpmPackageGroupResponse.md +36 -35
  74. data/docs/RpmPackageLangpacksResponse.md +18 -17
  75. data/docs/RpmPackageResponse.md +100 -99
  76. data/docs/RpmPruneApi.md +30 -13
  77. data/docs/RpmRepoMetadataFileResponse.md +36 -35
  78. data/docs/RpmRepositorySyncURL.md +16 -15
  79. data/docs/RpmRpmAlternateContentSource.md +14 -13
  80. data/docs/RpmRpmAlternateContentSourceResponse.md +22 -21
  81. data/docs/RpmRpmDistribution.md +22 -21
  82. data/docs/RpmRpmDistributionResponse.md +34 -33
  83. data/docs/RpmRpmPublication.md +24 -23
  84. data/docs/RpmRpmPublicationResponse.md +34 -33
  85. data/docs/RpmRpmRemote.md +50 -49
  86. data/docs/RpmRpmRemoteResponse.md +50 -49
  87. data/docs/RpmRpmRemoteResponseHiddenFieldsInner.md +20 -0
  88. data/docs/RpmRpmRepository.md +40 -39
  89. data/docs/RpmRpmRepositoryResponse.md +54 -53
  90. data/docs/RpmUlnRemote.md +50 -49
  91. data/docs/RpmUlnRemoteResponse.md +50 -49
  92. data/docs/RpmUpdateCollection.md +12 -11
  93. data/docs/RpmUpdateCollectionResponse.md +14 -13
  94. data/docs/RpmUpdateRecordResponse.md +50 -49
  95. data/docs/SetLabel.md +10 -9
  96. data/docs/SetLabelResponse.md +10 -9
  97. data/docs/SkipTypesEnum.md +4 -5
  98. data/docs/SyncPolicyEnum.md +4 -5
  99. data/docs/TaskGroupOperationResponse.md +8 -7
  100. data/docs/UnsetLabel.md +8 -7
  101. data/docs/UnsetLabelResponse.md +10 -9
  102. data/docs/VariantResponse.md +26 -25
  103. data/lib/pulp_rpm_client/api/acs_rpm_api.rb +76 -50
  104. data/lib/pulp_rpm_client/api/content_advisories_api.rb +20 -14
  105. data/lib/pulp_rpm_client/api/content_distribution_trees_api.rb +11 -9
  106. data/lib/pulp_rpm_client/api/content_modulemd_defaults_api.rb +20 -14
  107. data/lib/pulp_rpm_client/api/content_modulemd_obsoletes_api.rb +20 -14
  108. data/lib/pulp_rpm_client/api/content_modulemds_api.rb +20 -14
  109. data/lib/pulp_rpm_client/api/content_packagecategories_api.rb +11 -9
  110. data/lib/pulp_rpm_client/api/content_packageenvironments_api.rb +11 -9
  111. data/lib/pulp_rpm_client/api/content_packagegroups_api.rb +11 -9
  112. data/lib/pulp_rpm_client/api/content_packagelangpacks_api.rb +11 -9
  113. data/lib/pulp_rpm_client/api/content_packages_api.rb +20 -14
  114. data/lib/pulp_rpm_client/api/content_repo_metadata_files_api.rb +11 -9
  115. data/lib/pulp_rpm_client/api/distributions_rpm_api.rb +89 -56
  116. data/lib/pulp_rpm_client/api/publications_rpm_api.rb +67 -47
  117. data/lib/pulp_rpm_client/api/remotes_rpm_api.rb +104 -68
  118. data/lib/pulp_rpm_client/api/remotes_uln_api.rb +104 -68
  119. data/lib/pulp_rpm_client/api/repositories_rpm_api.rb +107 -66
  120. data/lib/pulp_rpm_client/api/repositories_rpm_versions_api.rb +40 -30
  121. data/lib/pulp_rpm_client/api/rpm_comps_api.rb +10 -6
  122. data/lib/pulp_rpm_client/api/rpm_copy_api.rb +10 -6
  123. data/lib/pulp_rpm_client/api/rpm_prune_api.rb +10 -6
  124. data/lib/pulp_rpm_client/api_client.rb +137 -102
  125. data/lib/pulp_rpm_client/api_error.rb +2 -1
  126. data/lib/pulp_rpm_client/configuration.rb +162 -21
  127. data/lib/pulp_rpm_client/models/addon_response.rb +40 -22
  128. data/lib/pulp_rpm_client/models/artifact_response.rb +34 -24
  129. data/lib/pulp_rpm_client/models/async_operation_response.rb +32 -22
  130. data/lib/pulp_rpm_client/models/checksum_response.rb +34 -22
  131. data/lib/pulp_rpm_client/models/compression_type_enum.rb +8 -4
  132. data/lib/pulp_rpm_client/models/content_summary_response.rb +36 -22
  133. data/lib/pulp_rpm_client/models/copy.rb +34 -28
  134. data/lib/pulp_rpm_client/models/image_response.rb +38 -22
  135. data/lib/pulp_rpm_client/models/my_permissions_response.rb +32 -22
  136. data/lib/pulp_rpm_client/models/nested_role.rb +32 -22
  137. data/lib/pulp_rpm_client/models/nested_role_response.rb +32 -22
  138. data/lib/pulp_rpm_client/models/object_roles_response.rb +32 -22
  139. data/lib/pulp_rpm_client/models/package_checksum_type_enum.rb +8 -4
  140. data/lib/pulp_rpm_client/models/paginated_repository_version_response_list.rb +34 -22
  141. data/lib/pulp_rpm_client/models/paginatedrpm_distribution_tree_response_list.rb +34 -22
  142. data/lib/pulp_rpm_client/models/paginatedrpm_modulemd_defaults_response_list.rb +34 -22
  143. data/lib/pulp_rpm_client/models/paginatedrpm_modulemd_obsolete_response_list.rb +34 -22
  144. data/lib/pulp_rpm_client/models/paginatedrpm_modulemd_response_list.rb +34 -22
  145. data/lib/pulp_rpm_client/models/paginatedrpm_package_category_response_list.rb +34 -22
  146. data/lib/pulp_rpm_client/models/paginatedrpm_package_environment_response_list.rb +34 -22
  147. data/lib/pulp_rpm_client/models/paginatedrpm_package_group_response_list.rb +34 -22
  148. data/lib/pulp_rpm_client/models/paginatedrpm_package_langpacks_response_list.rb +34 -22
  149. data/lib/pulp_rpm_client/models/paginatedrpm_package_response_list.rb +34 -22
  150. data/lib/pulp_rpm_client/models/paginatedrpm_repo_metadata_file_response_list.rb +34 -22
  151. data/lib/pulp_rpm_client/models/paginatedrpm_rpm_alternate_content_source_response_list.rb +34 -22
  152. data/lib/pulp_rpm_client/models/paginatedrpm_rpm_distribution_response_list.rb +34 -22
  153. data/lib/pulp_rpm_client/models/paginatedrpm_rpm_publication_response_list.rb +34 -22
  154. data/lib/pulp_rpm_client/models/paginatedrpm_rpm_remote_response_list.rb +34 -22
  155. data/lib/pulp_rpm_client/models/paginatedrpm_rpm_repository_response_list.rb +34 -22
  156. data/lib/pulp_rpm_client/models/paginatedrpm_uln_remote_response_list.rb +34 -22
  157. data/lib/pulp_rpm_client/models/paginatedrpm_update_record_response_list.rb +34 -22
  158. data/lib/pulp_rpm_client/models/patchedrpm_rpm_alternate_content_source.rb +36 -24
  159. data/lib/pulp_rpm_client/models/patchedrpm_rpm_distribution.rb +40 -24
  160. data/lib/pulp_rpm_client/models/patchedrpm_rpm_remote.rb +82 -44
  161. data/lib/pulp_rpm_client/models/patchedrpm_rpm_repository.rb +68 -25
  162. data/lib/pulp_rpm_client/models/patchedrpm_uln_remote.rb +92 -46
  163. data/lib/pulp_rpm_client/models/policy_enum.rb +8 -4
  164. data/lib/pulp_rpm_client/models/prune_packages.rb +37 -23
  165. data/lib/pulp_rpm_client/models/repair.rb +30 -22
  166. data/lib/pulp_rpm_client/models/repository_add_remove_content.rb +30 -22
  167. data/lib/pulp_rpm_client/models/repository_version_response.rb +32 -24
  168. data/lib/pulp_rpm_client/models/rpm_distribution_tree_response.rb +77 -23
  169. data/lib/pulp_rpm_client/models/rpm_modulemd.rb +50 -22
  170. data/lib/pulp_rpm_client/models/rpm_modulemd_defaults.rb +39 -27
  171. data/lib/pulp_rpm_client/models/rpm_modulemd_defaults_response.rb +39 -29
  172. data/lib/pulp_rpm_client/models/rpm_modulemd_obsolete.rb +55 -27
  173. data/lib/pulp_rpm_client/models/rpm_modulemd_obsolete_response.rb +50 -24
  174. data/lib/pulp_rpm_client/models/rpm_modulemd_response.rb +50 -24
  175. data/lib/pulp_rpm_client/models/rpm_package_category_response.rb +48 -24
  176. data/lib/pulp_rpm_client/models/rpm_package_environment_response.rb +50 -24
  177. data/lib/pulp_rpm_client/models/rpm_package_group_response.rb +48 -24
  178. data/lib/pulp_rpm_client/models/rpm_package_langpacks_response.rb +36 -24
  179. data/lib/pulp_rpm_client/models/rpm_package_response.rb +42 -24
  180. data/lib/pulp_rpm_client/models/rpm_repo_metadata_file_response.rb +40 -24
  181. data/lib/pulp_rpm_client/models/rpm_repository_sync_url.rb +52 -22
  182. data/lib/pulp_rpm_client/models/rpm_rpm_alternate_content_source.rb +35 -23
  183. data/lib/pulp_rpm_client/models/rpm_rpm_alternate_content_source_response.rb +37 -25
  184. data/lib/pulp_rpm_client/models/rpm_rpm_distribution.rb +34 -22
  185. data/lib/pulp_rpm_client/models/rpm_rpm_distribution_response.rb +36 -24
  186. data/lib/pulp_rpm_client/models/rpm_rpm_publication.rb +53 -22
  187. data/lib/pulp_rpm_client/models/rpm_rpm_publication_response.rb +55 -24
  188. data/lib/pulp_rpm_client/models/rpm_rpm_remote.rb +76 -42
  189. data/lib/pulp_rpm_client/models/rpm_rpm_remote_response.rb +79 -45
  190. data/lib/pulp_rpm_client/models/{rpm_rpm_remote_response_hidden_fields.rb → rpm_rpm_remote_response_hidden_fields_inner.rb} +37 -25
  191. data/lib/pulp_rpm_client/models/rpm_rpm_repository.rb +65 -24
  192. data/lib/pulp_rpm_client/models/rpm_rpm_repository_response.rb +67 -26
  193. data/lib/pulp_rpm_client/models/rpm_uln_remote.rb +80 -42
  194. data/lib/pulp_rpm_client/models/rpm_uln_remote_response.rb +79 -45
  195. data/lib/pulp_rpm_client/models/rpm_update_collection.rb +36 -22
  196. data/lib/pulp_rpm_client/models/rpm_update_collection_response.rb +36 -22
  197. data/lib/pulp_rpm_client/models/rpm_update_record_response.rb +32 -24
  198. data/lib/pulp_rpm_client/models/set_label.rb +34 -22
  199. data/lib/pulp_rpm_client/models/set_label_response.rb +34 -22
  200. data/lib/pulp_rpm_client/models/skip_types_enum.rb +8 -4
  201. data/lib/pulp_rpm_client/models/sync_policy_enum.rb +8 -4
  202. data/lib/pulp_rpm_client/models/task_group_operation_response.rb +32 -22
  203. data/lib/pulp_rpm_client/models/unset_label.rb +32 -22
  204. data/lib/pulp_rpm_client/models/unset_label_response.rb +32 -22
  205. data/lib/pulp_rpm_client/models/variant_response.rb +50 -22
  206. data/lib/pulp_rpm_client/version.rb +2 -2
  207. data/lib/pulp_rpm_client.rb +2 -5
  208. data/pulp_rpm_client.gemspec +9 -6
  209. data/spec/api/acs_rpm_api_spec.rb +12 -12
  210. data/spec/api/content_advisories_api_spec.rb +4 -4
  211. data/spec/api/content_distribution_trees_api_spec.rb +3 -3
  212. data/spec/api/content_modulemd_defaults_api_spec.rb +4 -4
  213. data/spec/api/content_modulemd_obsoletes_api_spec.rb +4 -4
  214. data/spec/api/content_modulemds_api_spec.rb +4 -4
  215. data/spec/api/content_packagecategories_api_spec.rb +3 -3
  216. data/spec/api/content_packageenvironments_api_spec.rb +3 -3
  217. data/spec/api/content_packagegroups_api_spec.rb +3 -3
  218. data/spec/api/content_packagelangpacks_api_spec.rb +3 -3
  219. data/spec/api/content_packages_api_spec.rb +4 -4
  220. data/spec/api/content_repo_metadata_files_api_spec.rb +3 -3
  221. data/spec/api/distributions_rpm_api_spec.rb +13 -13
  222. data/spec/api/publications_rpm_api_spec.rb +16 -15
  223. data/spec/api/remotes_rpm_api_spec.rb +20 -19
  224. data/spec/api/remotes_uln_api_spec.rb +20 -19
  225. data/spec/api/repositories_rpm_api_spec.rb +15 -15
  226. data/spec/api/repositories_rpm_versions_api_spec.rb +12 -11
  227. data/spec/api/rpm_comps_api_spec.rb +2 -2
  228. data/spec/api/rpm_copy_api_spec.rb +2 -2
  229. data/spec/api/rpm_prune_api_spec.rb +2 -2
  230. data/spec/models/addon_response_spec.rb +11 -16
  231. data/spec/models/artifact_response_spec.rb +18 -23
  232. data/spec/models/async_operation_response_spec.rb +7 -12
  233. data/spec/models/checksum_response_spec.rb +8 -13
  234. data/spec/models/compression_type_enum_spec.rb +6 -11
  235. data/spec/models/content_summary_response_spec.rb +9 -14
  236. data/spec/models/copy_spec.rb +8 -13
  237. data/spec/models/image_response_spec.rb +10 -15
  238. data/spec/models/my_permissions_response_spec.rb +7 -12
  239. data/spec/models/nested_role_response_spec.rb +9 -14
  240. data/spec/models/nested_role_spec.rb +9 -14
  241. data/spec/models/object_roles_response_spec.rb +7 -12
  242. data/spec/models/package_checksum_type_enum_spec.rb +6 -11
  243. data/spec/models/paginated_repository_version_response_list_spec.rb +10 -15
  244. data/spec/models/paginatedrpm_distribution_tree_response_list_spec.rb +10 -15
  245. data/spec/models/paginatedrpm_modulemd_defaults_response_list_spec.rb +10 -15
  246. data/spec/models/paginatedrpm_modulemd_obsolete_response_list_spec.rb +10 -15
  247. data/spec/models/paginatedrpm_modulemd_response_list_spec.rb +10 -15
  248. data/spec/models/paginatedrpm_package_category_response_list_spec.rb +10 -15
  249. data/spec/models/paginatedrpm_package_environment_response_list_spec.rb +10 -15
  250. data/spec/models/paginatedrpm_package_group_response_list_spec.rb +10 -15
  251. data/spec/models/paginatedrpm_package_langpacks_response_list_spec.rb +10 -15
  252. data/spec/models/paginatedrpm_package_response_list_spec.rb +10 -15
  253. data/spec/models/paginatedrpm_repo_metadata_file_response_list_spec.rb +10 -15
  254. data/spec/models/paginatedrpm_rpm_alternate_content_source_response_list_spec.rb +10 -15
  255. data/spec/models/paginatedrpm_rpm_distribution_response_list_spec.rb +10 -15
  256. data/spec/models/paginatedrpm_rpm_publication_response_list_spec.rb +10 -15
  257. data/spec/models/paginatedrpm_rpm_remote_response_list_spec.rb +10 -15
  258. data/spec/models/paginatedrpm_rpm_repository_response_list_spec.rb +10 -15
  259. data/spec/models/paginatedrpm_uln_remote_response_list_spec.rb +10 -15
  260. data/spec/models/paginatedrpm_update_record_response_list_spec.rb +10 -15
  261. data/spec/models/patchedrpm_rpm_alternate_content_source_spec.rb +10 -15
  262. data/spec/models/patchedrpm_rpm_distribution_spec.rb +14 -19
  263. data/spec/models/patchedrpm_rpm_remote_spec.rb +28 -33
  264. data/spec/models/patchedrpm_rpm_repository_spec.rb +23 -28
  265. data/spec/models/patchedrpm_uln_remote_spec.rb +28 -33
  266. data/spec/models/policy_enum_spec.rb +6 -11
  267. data/spec/models/prune_packages_spec.rb +9 -14
  268. data/spec/models/repair_spec.rb +7 -12
  269. data/spec/models/repository_add_remove_content_spec.rb +9 -14
  270. data/spec/models/repository_version_response_spec.rb +14 -19
  271. data/spec/models/rpm_distribution_tree_response_spec.rb +31 -30
  272. data/spec/models/rpm_modulemd_defaults_response_spec.rb +13 -18
  273. data/spec/models/rpm_modulemd_defaults_spec.rb +11 -16
  274. data/spec/models/rpm_modulemd_obsolete_response_spec.rb +19 -24
  275. data/spec/models/rpm_modulemd_obsolete_spec.rb +17 -22
  276. data/spec/models/rpm_modulemd_response_spec.rb +21 -26
  277. data/spec/models/rpm_modulemd_spec.rb +19 -24
  278. data/spec/models/rpm_package_category_response_spec.rb +18 -23
  279. data/spec/models/rpm_package_environment_response_spec.rb +19 -24
  280. data/spec/models/rpm_package_group_response_spec.rb +21 -26
  281. data/spec/models/rpm_package_langpacks_response_spec.rb +12 -17
  282. data/spec/models/rpm_package_response_spec.rb +53 -58
  283. data/spec/models/rpm_repo_metadata_file_response_spec.rb +21 -26
  284. data/spec/models/rpm_repository_sync_url_spec.rb +11 -16
  285. data/spec/models/rpm_rpm_alternate_content_source_response_spec.rb +14 -19
  286. data/spec/models/rpm_rpm_alternate_content_source_spec.rb +10 -15
  287. data/spec/models/rpm_rpm_distribution_response_spec.rb +20 -25
  288. data/spec/models/rpm_rpm_distribution_spec.rb +14 -19
  289. data/spec/models/rpm_rpm_publication_response_spec.rb +20 -25
  290. data/spec/models/rpm_rpm_publication_spec.rb +15 -20
  291. data/spec/models/{rpm_rpm_remote_response_hidden_fields_spec.rb → rpm_rpm_remote_response_hidden_fields_inner_spec.rb} +11 -16
  292. data/spec/models/rpm_rpm_remote_response_spec.rb +28 -33
  293. data/spec/models/rpm_rpm_remote_spec.rb +28 -33
  294. data/spec/models/rpm_rpm_repository_response_spec.rb +30 -35
  295. data/spec/models/rpm_rpm_repository_spec.rb +23 -28
  296. data/spec/models/rpm_uln_remote_response_spec.rb +28 -33
  297. data/spec/models/rpm_uln_remote_spec.rb +28 -33
  298. data/spec/models/rpm_update_collection_response_spec.rb +10 -15
  299. data/spec/models/rpm_update_collection_spec.rb +9 -14
  300. data/spec/models/rpm_update_record_response_spec.rb +28 -33
  301. data/spec/models/set_label_response_spec.rb +8 -13
  302. data/spec/models/set_label_spec.rb +8 -13
  303. data/spec/models/skip_types_enum_spec.rb +6 -11
  304. data/spec/models/sync_policy_enum_spec.rb +6 -11
  305. data/spec/models/task_group_operation_response_spec.rb +7 -12
  306. data/spec/models/unset_label_response_spec.rb +8 -13
  307. data/spec/models/unset_label_spec.rb +7 -12
  308. data/spec/models/variant_response_spec.rb +16 -21
  309. data/spec/spec_helper.rb +1 -1
  310. metadata +124 -112
  311. data/docs/CompsXml.md +0 -21
  312. data/docs/RpmPackage.md +0 -27
  313. data/docs/RpmRpmRemoteResponseHiddenFields.md +0 -19
  314. data/docs/RpmUpdateRecord.md +0 -23
  315. data/lib/pulp_rpm_client/models/comps_xml.rb +0 -233
  316. data/lib/pulp_rpm_client/models/rpm_package.rb +0 -288
  317. data/lib/pulp_rpm_client/models/rpm_update_record.rb +0 -253
  318. data/spec/api_client_spec.rb +0 -188
  319. data/spec/configuration_spec.rb +0 -42
  320. data/spec/models/comps_xml_spec.rb +0 -53
  321. data/spec/models/rpm_package_spec.rb +0 -71
  322. data/spec/models/rpm_update_record_spec.rb +0 -59
@@ -6,11 +6,12 @@
6
6
  The version of the OpenAPI document: v3
7
7
  Contact: pulp-list@redhat.com
8
8
  Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 4.3.1
9
+ Generator version: 7.10.0
10
10
 
11
11
  =end
12
12
 
13
13
  require 'date'
14
+ require 'time'
14
15
 
15
16
  module PulpRpmClient
16
17
  # A Serializer for RpmPublication.
@@ -55,6 +56,28 @@ module PulpRpmClient
55
56
  # The compression type to use for metadata files. * `zstd` - zstd * `gz` - gz
56
57
  attr_accessor :compression_type
57
58
 
59
+ class EnumAttributeValidator
60
+ attr_reader :datatype
61
+ attr_reader :allowable_values
62
+
63
+ def initialize(datatype, allowable_values)
64
+ @allowable_values = allowable_values.map do |value|
65
+ case datatype.to_s
66
+ when /Integer/i
67
+ value.to_i
68
+ when /Float/i
69
+ value.to_f
70
+ else
71
+ value
72
+ end
73
+ end
74
+ end
75
+
76
+ def valid?(value)
77
+ !value || allowable_values.include?(value)
78
+ end
79
+ end
80
+
58
81
  # Attribute mapping from ruby-style variable name to JSON key.
59
82
  def self.attribute_map
60
83
  {
@@ -75,13 +98,18 @@ module PulpRpmClient
75
98
  }
76
99
  end
77
100
 
101
+ # Returns all the JSON keys this model knows about
102
+ def self.acceptable_attributes
103
+ attribute_map.values
104
+ end
105
+
78
106
  # Attribute type mapping.
79
107
  def self.openapi_types
80
108
  {
81
109
  :'pulp_href' => :'String',
82
110
  :'prn' => :'String',
83
- :'pulp_created' => :'DateTime',
84
- :'pulp_last_updated' => :'DateTime',
111
+ :'pulp_created' => :'Time',
112
+ :'pulp_last_updated' => :'Time',
85
113
  :'repository_version' => :'String',
86
114
  :'repository' => :'String',
87
115
  :'checksum_type' => :'PackageChecksumTypeEnum',
@@ -100,6 +128,7 @@ module PulpRpmClient
100
128
  Set.new([
101
129
  :'gpgcheck',
102
130
  :'repo_gpgcheck',
131
+ :'repo_config',
103
132
  ])
104
133
  end
105
134
 
@@ -180,6 +209,7 @@ module PulpRpmClient
180
209
  # Show invalid properties with the reasons. Usually used together with valid?
181
210
  # @return Array for valid properties with the reasons
182
211
  def list_invalid_properties
212
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
183
213
  invalid_properties = Array.new
184
214
  if !@gpgcheck.nil? && @gpgcheck > 1
185
215
  invalid_properties.push('invalid value for "gpgcheck", must be smaller than or equal to 1.')
@@ -203,6 +233,7 @@ module PulpRpmClient
203
233
  # Check to see if the all the properties in the model are valid
204
234
  # @return true if the model is valid
205
235
  def valid?
236
+ warn '[DEPRECATED] the `valid?` method is obsolete'
206
237
  return false if !@gpgcheck.nil? && @gpgcheck > 1
207
238
  return false if !@gpgcheck.nil? && @gpgcheck < 0
208
239
  return false if !@repo_gpgcheck.nil? && @repo_gpgcheck > 1
@@ -275,37 +306,33 @@ module PulpRpmClient
275
306
  # @param [Hash] attributes Model attributes in the form of hash
276
307
  # @return [Object] Returns the model itself
277
308
  def self.build_from_hash(attributes)
278
- new.build_from_hash(attributes)
279
- end
280
-
281
- # Builds the object from hash
282
- # @param [Hash] attributes Model attributes in the form of hash
283
- # @return [Object] Returns the model itself
284
- def build_from_hash(attributes)
285
309
  return nil unless attributes.is_a?(Hash)
286
- self.class.openapi_types.each_pair do |key, type|
287
- if type =~ /\AArray<(.*)>/i
310
+ attributes = attributes.transform_keys(&:to_sym)
311
+ transformed_hash = {}
312
+ openapi_types.each_pair do |key, type|
313
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
314
+ transformed_hash["#{key}"] = nil
315
+ elsif type =~ /\AArray<(.*)>/i
288
316
  # check to ensure the input is an array given that the attribute
289
317
  # is documented as an array but the input is not
290
- if attributes[self.class.attribute_map[key]].is_a?(Array)
291
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
318
+ if attributes[attribute_map[key]].is_a?(Array)
319
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
292
320
  end
293
- elsif !attributes[self.class.attribute_map[key]].nil?
294
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
295
- end # or else data not found in attributes(hash), not an issue as the data can be optional
321
+ elsif !attributes[attribute_map[key]].nil?
322
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
323
+ end
296
324
  end
297
-
298
- self
325
+ new(transformed_hash)
299
326
  end
300
327
 
301
328
  # Deserializes the data based on type
302
329
  # @param string type Data type
303
330
  # @param string value Value to be deserialized
304
331
  # @return [Object] Deserialized data
305
- def _deserialize(type, value)
332
+ def self._deserialize(type, value)
306
333
  case type.to_sym
307
- when :DateTime
308
- DateTime.parse(value)
334
+ when :Time
335
+ Time.parse(value)
309
336
  when :Date
310
337
  Date.parse(value)
311
338
  when :String
@@ -335,7 +362,9 @@ module PulpRpmClient
335
362
  end
336
363
  end
337
364
  else # model
338
- PulpRpmClient.const_get(type).build_from_hash(value)
365
+ # models (e.g. Pet) or oneOf
366
+ klass = PulpRpmClient.const_get(type)
367
+ klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
339
368
  end
340
369
  end
341
370
 
@@ -361,7 +390,7 @@ module PulpRpmClient
361
390
  is_nullable = self.class.openapi_nullable.include?(attr)
362
391
  next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
363
392
  end
364
-
393
+
365
394
  hash[param] = _to_hash(value)
366
395
  end
367
396
  hash
@@ -384,5 +413,7 @@ module PulpRpmClient
384
413
  value
385
414
  end
386
415
  end
416
+
387
417
  end
418
+
388
419
  end
@@ -6,11 +6,12 @@
6
6
  The version of the OpenAPI document: v3
7
7
  Contact: pulp-list@redhat.com
8
8
  Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 4.3.1
9
+ Generator version: 7.10.0
10
10
 
11
11
  =end
12
12
 
13
13
  require 'date'
14
+ require 'time'
14
15
 
15
16
  module PulpRpmClient
16
17
  # A Serializer for RpmRemote.
@@ -80,6 +81,28 @@ module PulpRpmClient
80
81
  # Authentication token for SLES repositories.
81
82
  attr_accessor :sles_auth_token
82
83
 
84
+ class EnumAttributeValidator
85
+ attr_reader :datatype
86
+ attr_reader :allowable_values
87
+
88
+ def initialize(datatype, allowable_values)
89
+ @allowable_values = allowable_values.map do |value|
90
+ case datatype.to_s
91
+ when /Integer/i
92
+ value.to_i
93
+ when /Float/i
94
+ value.to_f
95
+ else
96
+ value
97
+ end
98
+ end
99
+ end
100
+
101
+ def valid?(value)
102
+ !value || allowable_values.include?(value)
103
+ end
104
+ end
105
+
83
106
  # Attribute mapping from ruby-style variable name to JSON key.
84
107
  def self.attribute_map
85
108
  {
@@ -108,6 +131,11 @@ module PulpRpmClient
108
131
  }
109
132
  end
110
133
 
134
+ # Returns all the JSON keys this model knows about
135
+ def self.acceptable_attributes
136
+ attribute_map.values
137
+ end
138
+
111
139
  # Attribute type mapping.
112
140
  def self.openapi_types
113
141
  {
@@ -175,10 +203,14 @@ module PulpRpmClient
175
203
 
176
204
  if attributes.key?(:'name')
177
205
  self.name = attributes[:'name']
206
+ else
207
+ self.name = nil
178
208
  end
179
209
 
180
210
  if attributes.key?(:'url')
181
211
  self.url = attributes[:'url']
212
+ else
213
+ self.url = nil
182
214
  end
183
215
 
184
216
  if attributes.key?(:'ca_cert')
@@ -269,6 +301,7 @@ module PulpRpmClient
269
301
  # Show invalid properties with the reasons. Usually used together with valid?
270
302
  # @return Array for valid properties with the reasons
271
303
  def list_invalid_properties
304
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
272
305
  invalid_properties = Array.new
273
306
  if @name.nil?
274
307
  invalid_properties.push('invalid value for "name", name cannot be nil.')
@@ -322,20 +355,20 @@ module PulpRpmClient
322
355
  invalid_properties.push('invalid value for "download_concurrency", must be greater than or equal to 1.')
323
356
  end
324
357
 
325
- if !@total_timeout.nil? && @total_timeout < 0
326
- invalid_properties.push('invalid value for "total_timeout", must be greater than or equal to 0.')
358
+ if !@total_timeout.nil? && @total_timeout < 0.0
359
+ invalid_properties.push('invalid value for "total_timeout", must be greater than or equal to 0.0.')
327
360
  end
328
361
 
329
- if !@connect_timeout.nil? && @connect_timeout < 0
330
- invalid_properties.push('invalid value for "connect_timeout", must be greater than or equal to 0.')
362
+ if !@connect_timeout.nil? && @connect_timeout < 0.0
363
+ invalid_properties.push('invalid value for "connect_timeout", must be greater than or equal to 0.0.')
331
364
  end
332
365
 
333
- if !@sock_connect_timeout.nil? && @sock_connect_timeout < 0
334
- invalid_properties.push('invalid value for "sock_connect_timeout", must be greater than or equal to 0.')
366
+ if !@sock_connect_timeout.nil? && @sock_connect_timeout < 0.0
367
+ invalid_properties.push('invalid value for "sock_connect_timeout", must be greater than or equal to 0.0.')
335
368
  end
336
369
 
337
- if !@sock_read_timeout.nil? && @sock_read_timeout < 0
338
- invalid_properties.push('invalid value for "sock_read_timeout", must be greater than or equal to 0.')
370
+ if !@sock_read_timeout.nil? && @sock_read_timeout < 0.0
371
+ invalid_properties.push('invalid value for "sock_read_timeout", must be greater than or equal to 0.0.')
339
372
  end
340
373
 
341
374
  if !@sles_auth_token.nil? && @sles_auth_token.to_s.length < 1
@@ -348,6 +381,7 @@ module PulpRpmClient
348
381
  # Check to see if the all the properties in the model are valid
349
382
  # @return true if the model is valid
350
383
  def valid?
384
+ warn '[DEPRECATED] the `valid?` method is obsolete'
351
385
  return false if @name.nil?
352
386
  return false if @name.to_s.length < 1
353
387
  return false if @url.nil?
@@ -361,10 +395,10 @@ module PulpRpmClient
361
395
  return false if !@username.nil? && @username.to_s.length < 1
362
396
  return false if !@password.nil? && @password.to_s.length < 1
363
397
  return false if !@download_concurrency.nil? && @download_concurrency < 1
364
- return false if !@total_timeout.nil? && @total_timeout < 0
365
- return false if !@connect_timeout.nil? && @connect_timeout < 0
366
- return false if !@sock_connect_timeout.nil? && @sock_connect_timeout < 0
367
- return false if !@sock_read_timeout.nil? && @sock_read_timeout < 0
398
+ return false if !@total_timeout.nil? && @total_timeout < 0.0
399
+ return false if !@connect_timeout.nil? && @connect_timeout < 0.0
400
+ return false if !@sock_connect_timeout.nil? && @sock_connect_timeout < 0.0
401
+ return false if !@sock_read_timeout.nil? && @sock_read_timeout < 0.0
368
402
  return false if !@sles_auth_token.nil? && @sles_auth_token.to_s.length < 1
369
403
  true
370
404
  end
@@ -490,8 +524,8 @@ module PulpRpmClient
490
524
  # Custom attribute writer method with validation
491
525
  # @param [Object] total_timeout Value to be assigned
492
526
  def total_timeout=(total_timeout)
493
- if !total_timeout.nil? && total_timeout < 0
494
- fail ArgumentError, 'invalid value for "total_timeout", must be greater than or equal to 0.'
527
+ if !total_timeout.nil? && total_timeout < 0.0
528
+ fail ArgumentError, 'invalid value for "total_timeout", must be greater than or equal to 0.0.'
495
529
  end
496
530
 
497
531
  @total_timeout = total_timeout
@@ -500,8 +534,8 @@ module PulpRpmClient
500
534
  # Custom attribute writer method with validation
501
535
  # @param [Object] connect_timeout Value to be assigned
502
536
  def connect_timeout=(connect_timeout)
503
- if !connect_timeout.nil? && connect_timeout < 0
504
- fail ArgumentError, 'invalid value for "connect_timeout", must be greater than or equal to 0.'
537
+ if !connect_timeout.nil? && connect_timeout < 0.0
538
+ fail ArgumentError, 'invalid value for "connect_timeout", must be greater than or equal to 0.0.'
505
539
  end
506
540
 
507
541
  @connect_timeout = connect_timeout
@@ -510,8 +544,8 @@ module PulpRpmClient
510
544
  # Custom attribute writer method with validation
511
545
  # @param [Object] sock_connect_timeout Value to be assigned
512
546
  def sock_connect_timeout=(sock_connect_timeout)
513
- if !sock_connect_timeout.nil? && sock_connect_timeout < 0
514
- fail ArgumentError, 'invalid value for "sock_connect_timeout", must be greater than or equal to 0.'
547
+ if !sock_connect_timeout.nil? && sock_connect_timeout < 0.0
548
+ fail ArgumentError, 'invalid value for "sock_connect_timeout", must be greater than or equal to 0.0.'
515
549
  end
516
550
 
517
551
  @sock_connect_timeout = sock_connect_timeout
@@ -520,8 +554,8 @@ module PulpRpmClient
520
554
  # Custom attribute writer method with validation
521
555
  # @param [Object] sock_read_timeout Value to be assigned
522
556
  def sock_read_timeout=(sock_read_timeout)
523
- if !sock_read_timeout.nil? && sock_read_timeout < 0
524
- fail ArgumentError, 'invalid value for "sock_read_timeout", must be greater than or equal to 0.'
557
+ if !sock_read_timeout.nil? && sock_read_timeout < 0.0
558
+ fail ArgumentError, 'invalid value for "sock_read_timeout", must be greater than or equal to 0.0.'
525
559
  end
526
560
 
527
561
  @sock_read_timeout = sock_read_timeout
@@ -582,37 +616,33 @@ module PulpRpmClient
582
616
  # @param [Hash] attributes Model attributes in the form of hash
583
617
  # @return [Object] Returns the model itself
584
618
  def self.build_from_hash(attributes)
585
- new.build_from_hash(attributes)
586
- end
587
-
588
- # Builds the object from hash
589
- # @param [Hash] attributes Model attributes in the form of hash
590
- # @return [Object] Returns the model itself
591
- def build_from_hash(attributes)
592
619
  return nil unless attributes.is_a?(Hash)
593
- self.class.openapi_types.each_pair do |key, type|
594
- if type =~ /\AArray<(.*)>/i
620
+ attributes = attributes.transform_keys(&:to_sym)
621
+ transformed_hash = {}
622
+ openapi_types.each_pair do |key, type|
623
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
624
+ transformed_hash["#{key}"] = nil
625
+ elsif type =~ /\AArray<(.*)>/i
595
626
  # check to ensure the input is an array given that the attribute
596
627
  # is documented as an array but the input is not
597
- if attributes[self.class.attribute_map[key]].is_a?(Array)
598
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
628
+ if attributes[attribute_map[key]].is_a?(Array)
629
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
599
630
  end
600
- elsif !attributes[self.class.attribute_map[key]].nil?
601
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
602
- end # or else data not found in attributes(hash), not an issue as the data can be optional
631
+ elsif !attributes[attribute_map[key]].nil?
632
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
633
+ end
603
634
  end
604
-
605
- self
635
+ new(transformed_hash)
606
636
  end
607
637
 
608
638
  # Deserializes the data based on type
609
639
  # @param string type Data type
610
640
  # @param string value Value to be deserialized
611
641
  # @return [Object] Deserialized data
612
- def _deserialize(type, value)
642
+ def self._deserialize(type, value)
613
643
  case type.to_sym
614
- when :DateTime
615
- DateTime.parse(value)
644
+ when :Time
645
+ Time.parse(value)
616
646
  when :Date
617
647
  Date.parse(value)
618
648
  when :String
@@ -642,7 +672,9 @@ module PulpRpmClient
642
672
  end
643
673
  end
644
674
  else # model
645
- PulpRpmClient.const_get(type).build_from_hash(value)
675
+ # models (e.g. Pet) or oneOf
676
+ klass = PulpRpmClient.const_get(type)
677
+ klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
646
678
  end
647
679
  end
648
680
 
@@ -668,7 +700,7 @@ module PulpRpmClient
668
700
  is_nullable = self.class.openapi_nullable.include?(attr)
669
701
  next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
670
702
  end
671
-
703
+
672
704
  hash[param] = _to_hash(value)
673
705
  end
674
706
  hash
@@ -691,5 +723,7 @@ module PulpRpmClient
691
723
  value
692
724
  end
693
725
  end
726
+
694
727
  end
728
+
695
729
  end
@@ -6,11 +6,12 @@
6
6
  The version of the OpenAPI document: v3
7
7
  Contact: pulp-list@redhat.com
8
8
  Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 4.3.1
9
+ Generator version: 7.10.0
10
10
 
11
11
  =end
12
12
 
13
13
  require 'date'
14
+ require 'time'
14
15
 
15
16
  module PulpRpmClient
16
17
  # A Serializer for RpmRemote.
@@ -79,6 +80,28 @@ module PulpRpmClient
79
80
  # Authentication token for SLES repositories.
80
81
  attr_accessor :sles_auth_token
81
82
 
83
+ class EnumAttributeValidator
84
+ attr_reader :datatype
85
+ attr_reader :allowable_values
86
+
87
+ def initialize(datatype, allowable_values)
88
+ @allowable_values = allowable_values.map do |value|
89
+ case datatype.to_s
90
+ when /Integer/i
91
+ value.to_i
92
+ when /Float/i
93
+ value.to_f
94
+ else
95
+ value
96
+ end
97
+ end
98
+ end
99
+
100
+ def valid?(value)
101
+ !value || allowable_values.include?(value)
102
+ end
103
+ end
104
+
82
105
  # Attribute mapping from ruby-style variable name to JSON key.
83
106
  def self.attribute_map
84
107
  {
@@ -107,13 +130,18 @@ module PulpRpmClient
107
130
  }
108
131
  end
109
132
 
133
+ # Returns all the JSON keys this model knows about
134
+ def self.acceptable_attributes
135
+ attribute_map.values
136
+ end
137
+
110
138
  # Attribute type mapping.
111
139
  def self.openapi_types
112
140
  {
113
141
  :'pulp_href' => :'String',
114
142
  :'prn' => :'String',
115
- :'pulp_created' => :'DateTime',
116
- :'pulp_last_updated' => :'DateTime',
143
+ :'pulp_created' => :'Time',
144
+ :'pulp_last_updated' => :'Time',
117
145
  :'name' => :'String',
118
146
  :'url' => :'String',
119
147
  :'ca_cert' => :'String',
@@ -130,7 +158,7 @@ module PulpRpmClient
130
158
  :'sock_read_timeout' => :'Float',
131
159
  :'headers' => :'Array<Object>',
132
160
  :'rate_limit' => :'Integer',
133
- :'hidden_fields' => :'Array<RpmRpmRemoteResponseHiddenFields>',
161
+ :'hidden_fields' => :'Array<RpmRpmRemoteResponseHiddenFieldsInner>',
134
162
  :'sles_auth_token' => :'String'
135
163
  }
136
164
  end
@@ -185,10 +213,14 @@ module PulpRpmClient
185
213
 
186
214
  if attributes.key?(:'name')
187
215
  self.name = attributes[:'name']
216
+ else
217
+ self.name = nil
188
218
  end
189
219
 
190
220
  if attributes.key?(:'url')
191
221
  self.url = attributes[:'url']
222
+ else
223
+ self.url = nil
192
224
  end
193
225
 
194
226
  if attributes.key?(:'ca_cert')
@@ -265,6 +297,7 @@ module PulpRpmClient
265
297
  # Show invalid properties with the reasons. Usually used together with valid?
266
298
  # @return Array for valid properties with the reasons
267
299
  def list_invalid_properties
300
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
268
301
  invalid_properties = Array.new
269
302
  if @name.nil?
270
303
  invalid_properties.push('invalid value for "name", name cannot be nil.')
@@ -278,20 +311,20 @@ module PulpRpmClient
278
311
  invalid_properties.push('invalid value for "download_concurrency", must be greater than or equal to 1.')
279
312
  end
280
313
 
281
- if !@total_timeout.nil? && @total_timeout < 0
282
- invalid_properties.push('invalid value for "total_timeout", must be greater than or equal to 0.')
314
+ if !@total_timeout.nil? && @total_timeout < 0.0
315
+ invalid_properties.push('invalid value for "total_timeout", must be greater than or equal to 0.0.')
283
316
  end
284
317
 
285
- if !@connect_timeout.nil? && @connect_timeout < 0
286
- invalid_properties.push('invalid value for "connect_timeout", must be greater than or equal to 0.')
318
+ if !@connect_timeout.nil? && @connect_timeout < 0.0
319
+ invalid_properties.push('invalid value for "connect_timeout", must be greater than or equal to 0.0.')
287
320
  end
288
321
 
289
- if !@sock_connect_timeout.nil? && @sock_connect_timeout < 0
290
- invalid_properties.push('invalid value for "sock_connect_timeout", must be greater than or equal to 0.')
322
+ if !@sock_connect_timeout.nil? && @sock_connect_timeout < 0.0
323
+ invalid_properties.push('invalid value for "sock_connect_timeout", must be greater than or equal to 0.0.')
291
324
  end
292
325
 
293
- if !@sock_read_timeout.nil? && @sock_read_timeout < 0
294
- invalid_properties.push('invalid value for "sock_read_timeout", must be greater than or equal to 0.')
326
+ if !@sock_read_timeout.nil? && @sock_read_timeout < 0.0
327
+ invalid_properties.push('invalid value for "sock_read_timeout", must be greater than or equal to 0.0.')
295
328
  end
296
329
 
297
330
  invalid_properties
@@ -300,13 +333,14 @@ module PulpRpmClient
300
333
  # Check to see if the all the properties in the model are valid
301
334
  # @return true if the model is valid
302
335
  def valid?
336
+ warn '[DEPRECATED] the `valid?` method is obsolete'
303
337
  return false if @name.nil?
304
338
  return false if @url.nil?
305
339
  return false if !@download_concurrency.nil? && @download_concurrency < 1
306
- return false if !@total_timeout.nil? && @total_timeout < 0
307
- return false if !@connect_timeout.nil? && @connect_timeout < 0
308
- return false if !@sock_connect_timeout.nil? && @sock_connect_timeout < 0
309
- return false if !@sock_read_timeout.nil? && @sock_read_timeout < 0
340
+ return false if !@total_timeout.nil? && @total_timeout < 0.0
341
+ return false if !@connect_timeout.nil? && @connect_timeout < 0.0
342
+ return false if !@sock_connect_timeout.nil? && @sock_connect_timeout < 0.0
343
+ return false if !@sock_read_timeout.nil? && @sock_read_timeout < 0.0
310
344
  true
311
345
  end
312
346
 
@@ -323,8 +357,8 @@ module PulpRpmClient
323
357
  # Custom attribute writer method with validation
324
358
  # @param [Object] total_timeout Value to be assigned
325
359
  def total_timeout=(total_timeout)
326
- if !total_timeout.nil? && total_timeout < 0
327
- fail ArgumentError, 'invalid value for "total_timeout", must be greater than or equal to 0.'
360
+ if !total_timeout.nil? && total_timeout < 0.0
361
+ fail ArgumentError, 'invalid value for "total_timeout", must be greater than or equal to 0.0.'
328
362
  end
329
363
 
330
364
  @total_timeout = total_timeout
@@ -333,8 +367,8 @@ module PulpRpmClient
333
367
  # Custom attribute writer method with validation
334
368
  # @param [Object] connect_timeout Value to be assigned
335
369
  def connect_timeout=(connect_timeout)
336
- if !connect_timeout.nil? && connect_timeout < 0
337
- fail ArgumentError, 'invalid value for "connect_timeout", must be greater than or equal to 0.'
370
+ if !connect_timeout.nil? && connect_timeout < 0.0
371
+ fail ArgumentError, 'invalid value for "connect_timeout", must be greater than or equal to 0.0.'
338
372
  end
339
373
 
340
374
  @connect_timeout = connect_timeout
@@ -343,8 +377,8 @@ module PulpRpmClient
343
377
  # Custom attribute writer method with validation
344
378
  # @param [Object] sock_connect_timeout Value to be assigned
345
379
  def sock_connect_timeout=(sock_connect_timeout)
346
- if !sock_connect_timeout.nil? && sock_connect_timeout < 0
347
- fail ArgumentError, 'invalid value for "sock_connect_timeout", must be greater than or equal to 0.'
380
+ if !sock_connect_timeout.nil? && sock_connect_timeout < 0.0
381
+ fail ArgumentError, 'invalid value for "sock_connect_timeout", must be greater than or equal to 0.0.'
348
382
  end
349
383
 
350
384
  @sock_connect_timeout = sock_connect_timeout
@@ -353,8 +387,8 @@ module PulpRpmClient
353
387
  # Custom attribute writer method with validation
354
388
  # @param [Object] sock_read_timeout Value to be assigned
355
389
  def sock_read_timeout=(sock_read_timeout)
356
- if !sock_read_timeout.nil? && sock_read_timeout < 0
357
- fail ArgumentError, 'invalid value for "sock_read_timeout", must be greater than or equal to 0.'
390
+ if !sock_read_timeout.nil? && sock_read_timeout < 0.0
391
+ fail ArgumentError, 'invalid value for "sock_read_timeout", must be greater than or equal to 0.0.'
358
392
  end
359
393
 
360
394
  @sock_read_timeout = sock_read_timeout
@@ -405,37 +439,33 @@ module PulpRpmClient
405
439
  # @param [Hash] attributes Model attributes in the form of hash
406
440
  # @return [Object] Returns the model itself
407
441
  def self.build_from_hash(attributes)
408
- new.build_from_hash(attributes)
409
- end
410
-
411
- # Builds the object from hash
412
- # @param [Hash] attributes Model attributes in the form of hash
413
- # @return [Object] Returns the model itself
414
- def build_from_hash(attributes)
415
442
  return nil unless attributes.is_a?(Hash)
416
- self.class.openapi_types.each_pair do |key, type|
417
- if type =~ /\AArray<(.*)>/i
443
+ attributes = attributes.transform_keys(&:to_sym)
444
+ transformed_hash = {}
445
+ openapi_types.each_pair do |key, type|
446
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
447
+ transformed_hash["#{key}"] = nil
448
+ elsif type =~ /\AArray<(.*)>/i
418
449
  # check to ensure the input is an array given that the attribute
419
450
  # is documented as an array but the input is not
420
- if attributes[self.class.attribute_map[key]].is_a?(Array)
421
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
451
+ if attributes[attribute_map[key]].is_a?(Array)
452
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
422
453
  end
423
- elsif !attributes[self.class.attribute_map[key]].nil?
424
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
425
- end # or else data not found in attributes(hash), not an issue as the data can be optional
454
+ elsif !attributes[attribute_map[key]].nil?
455
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
456
+ end
426
457
  end
427
-
428
- self
458
+ new(transformed_hash)
429
459
  end
430
460
 
431
461
  # Deserializes the data based on type
432
462
  # @param string type Data type
433
463
  # @param string value Value to be deserialized
434
464
  # @return [Object] Deserialized data
435
- def _deserialize(type, value)
465
+ def self._deserialize(type, value)
436
466
  case type.to_sym
437
- when :DateTime
438
- DateTime.parse(value)
467
+ when :Time
468
+ Time.parse(value)
439
469
  when :Date
440
470
  Date.parse(value)
441
471
  when :String
@@ -465,7 +495,9 @@ module PulpRpmClient
465
495
  end
466
496
  end
467
497
  else # model
468
- PulpRpmClient.const_get(type).build_from_hash(value)
498
+ # models (e.g. Pet) or oneOf
499
+ klass = PulpRpmClient.const_get(type)
500
+ klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
469
501
  end
470
502
  end
471
503
 
@@ -491,7 +523,7 @@ module PulpRpmClient
491
523
  is_nullable = self.class.openapi_nullable.include?(attr)
492
524
  next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
493
525
  end
494
-
526
+
495
527
  hash[param] = _to_hash(value)
496
528
  end
497
529
  hash
@@ -514,5 +546,7 @@ module PulpRpmClient
514
546
  value
515
547
  end
516
548
  end
549
+
517
550
  end
551
+
518
552
  end