pulpcore_client 3.5.0 → 3.6.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (239) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +88 -44
  3. data/docs/AccessPoliciesApi.md +244 -0
  4. data/docs/AccessPolicy.md +21 -0
  5. data/docs/AccessPolicyResponse.md +25 -0
  6. data/docs/Artifact.md +2 -6
  7. data/docs/ArtifactResponse.md +35 -0
  8. data/docs/ArtifactsApi.md +40 -34
  9. data/docs/{ContentAppStatus.md → ContentAppStatusResponse.md} +2 -2
  10. data/docs/{DatabaseConnection.md → DatabaseConnectionResponse.md} +2 -2
  11. data/docs/ExportersCoreExportsApi.md +33 -33
  12. data/docs/ExportersPulpApi.md +51 -51
  13. data/docs/Group.md +17 -0
  14. data/docs/{GroupProgressReport.md → GroupProgressReportResponse.md} +2 -2
  15. data/docs/GroupResponse.md +21 -0
  16. data/docs/GroupUser.md +17 -0
  17. data/docs/GroupUserResponse.md +19 -0
  18. data/docs/GroupsApi.md +351 -0
  19. data/docs/GroupsModelPermissionsApi.md +128 -0
  20. data/docs/GroupsObjectPermissionsApi.md +247 -0
  21. data/docs/GroupsUsersApi.md +183 -0
  22. data/docs/{Import.md → ImportResponse.md} +2 -2
  23. data/docs/ImportersCoreImportsApi.md +33 -33
  24. data/docs/ImportersPulpApi.md +51 -51
  25. data/docs/InlineResponse200.md +3 -3
  26. data/docs/InlineResponse2001.md +3 -3
  27. data/docs/InlineResponse20010.md +23 -0
  28. data/docs/InlineResponse20011.md +23 -0
  29. data/docs/InlineResponse20012.md +23 -0
  30. data/docs/InlineResponse20013.md +23 -0
  31. data/docs/InlineResponse20014.md +23 -0
  32. data/docs/InlineResponse2002.md +3 -3
  33. data/docs/InlineResponse2003.md +3 -3
  34. data/docs/InlineResponse2004.md +3 -3
  35. data/docs/InlineResponse2005.md +3 -3
  36. data/docs/InlineResponse2006.md +3 -3
  37. data/docs/InlineResponse2007.md +3 -3
  38. data/docs/InlineResponse2008.md +3 -3
  39. data/docs/InlineResponse2009.md +3 -3
  40. data/docs/OrphansApi.md +2 -2
  41. data/docs/PatchedAccessPolicy.md +21 -0
  42. data/docs/PatchedGroup.md +17 -0
  43. data/docs/PatchedPulpExporter.md +23 -0
  44. data/docs/PatchedPulpImporter.md +19 -0
  45. data/docs/{TaskCancel.md → PatchedTaskCancel.md} +3 -3
  46. data/docs/PermissionResponse.md +23 -0
  47. data/docs/{ProgressReport.md → ProgressReportResponse.md} +2 -2
  48. data/docs/PulpExport.md +11 -11
  49. data/docs/PulpExportResponse.md +27 -0
  50. data/docs/PulpExporter.md +1 -5
  51. data/docs/PulpExporterResponse.md +27 -0
  52. data/docs/PulpImport.md +4 -2
  53. data/docs/PulpImporter.md +2 -6
  54. data/docs/PulpImporterResponse.md +23 -0
  55. data/docs/{RedisConnection.md → RedisConnectionResponse.md} +2 -2
  56. data/docs/{SigningService.md → SigningServiceResponse.md} +2 -2
  57. data/docs/SigningServicesApi.md +14 -14
  58. data/docs/StatusApi.md +8 -22
  59. data/docs/StatusResponse.md +27 -0
  60. data/docs/{Storage.md → StorageResponse.md} +2 -2
  61. data/docs/{TaskGroup.md → TaskGroupResponse.md} +3 -3
  62. data/docs/TaskGroupsApi.md +16 -12
  63. data/docs/{Task.md → TaskResponse.md} +5 -7
  64. data/docs/TasksApi.md +144 -88
  65. data/docs/Upload.md +1 -7
  66. data/docs/UploadChunk.md +2 -6
  67. data/docs/UploadChunkResponse.md +19 -0
  68. data/docs/{UploadDetail.md → UploadDetailResponse.md} +3 -3
  69. data/docs/UploadResponse.md +23 -0
  70. data/docs/UploadsApi.md +42 -40
  71. data/docs/UserGroupResponse.md +19 -0
  72. data/docs/UserResponse.md +35 -0
  73. data/docs/UsersApi.md +191 -0
  74. data/docs/{Version.md → VersionResponse.md} +2 -2
  75. data/docs/{Worker.md → WorkerResponse.md} +2 -2
  76. data/docs/WorkersApi.md +36 -32
  77. data/lib/pulpcore_client/api/access_policies_api.rb +301 -0
  78. data/lib/pulpcore_client/api/artifacts_api.rb +47 -65
  79. data/lib/pulpcore_client/api/exporters_core_exports_api.rb +51 -51
  80. data/lib/pulpcore_client/api/exporters_pulp_api.rb +71 -71
  81. data/lib/pulpcore_client/api/groups_api.rb +425 -0
  82. data/lib/pulpcore_client/api/groups_model_permissions_api.rb +161 -0
  83. data/lib/pulpcore_client/api/groups_object_permissions_api.rb +295 -0
  84. data/lib/pulpcore_client/api/groups_users_api.rb +229 -0
  85. data/lib/pulpcore_client/api/importers_core_imports_api.rb +51 -51
  86. data/lib/pulpcore_client/api/importers_pulp_api.rb +71 -71
  87. data/lib/pulpcore_client/api/orphans_api.rb +3 -3
  88. data/lib/pulpcore_client/api/signing_services_api.rb +18 -18
  89. data/lib/pulpcore_client/api/status_api.rb +11 -17
  90. data/lib/pulpcore_client/api/task_groups_api.rb +19 -15
  91. data/lib/pulpcore_client/api/tasks_api.rb +203 -125
  92. data/lib/pulpcore_client/api/uploads_api.rb +60 -66
  93. data/lib/pulpcore_client/api/users_api.rb +227 -0
  94. data/lib/pulpcore_client/api/workers_api.rb +46 -42
  95. data/lib/pulpcore_client/api_client.rb +2 -2
  96. data/lib/pulpcore_client/api_error.rb +2 -2
  97. data/lib/pulpcore_client/configuration.rb +3 -3
  98. data/lib/pulpcore_client/models/access_policy.rb +247 -0
  99. data/lib/pulpcore_client/models/access_policy_response.rb +266 -0
  100. data/lib/pulpcore_client/models/artifact.rb +8 -111
  101. data/lib/pulpcore_client/models/artifact_response.rb +308 -0
  102. data/lib/pulpcore_client/models/async_operation_response.rb +3 -2
  103. data/lib/pulpcore_client/models/{content_app_status.rb → content_app_status_response.rb} +6 -21
  104. data/lib/pulpcore_client/models/{database_connection.rb → database_connection_response.rb} +6 -6
  105. data/lib/pulpcore_client/models/group.rb +232 -0
  106. data/lib/pulpcore_client/models/{group_progress_report.rb → group_progress_report_response.rb} +6 -50
  107. data/lib/pulpcore_client/models/group_response.rb +250 -0
  108. data/lib/pulpcore_client/models/group_user.rb +232 -0
  109. data/lib/pulpcore_client/models/group_user_response.rb +241 -0
  110. data/lib/pulpcore_client/models/{import.rb → import_response.rb} +6 -5
  111. data/lib/pulpcore_client/models/inline_response200.rb +3 -13
  112. data/lib/pulpcore_client/models/inline_response2001.rb +3 -13
  113. data/lib/pulpcore_client/models/inline_response20010.rb +237 -0
  114. data/lib/pulpcore_client/models/inline_response20011.rb +237 -0
  115. data/lib/pulpcore_client/models/inline_response20012.rb +237 -0
  116. data/lib/pulpcore_client/models/inline_response20013.rb +237 -0
  117. data/lib/pulpcore_client/models/inline_response20014.rb +237 -0
  118. data/lib/pulpcore_client/models/inline_response2002.rb +3 -13
  119. data/lib/pulpcore_client/models/inline_response2003.rb +3 -13
  120. data/lib/pulpcore_client/models/inline_response2004.rb +3 -13
  121. data/lib/pulpcore_client/models/inline_response2005.rb +3 -13
  122. data/lib/pulpcore_client/models/inline_response2006.rb +3 -13
  123. data/lib/pulpcore_client/models/inline_response2007.rb +3 -13
  124. data/lib/pulpcore_client/models/inline_response2008.rb +3 -13
  125. data/lib/pulpcore_client/models/inline_response2009.rb +3 -13
  126. data/lib/pulpcore_client/models/patched_access_policy.rb +232 -0
  127. data/lib/pulpcore_client/models/patched_group.rb +223 -0
  128. data/lib/pulpcore_client/models/patched_pulp_exporter.rb +240 -0
  129. data/lib/pulpcore_client/models/patched_pulp_importer.rb +218 -0
  130. data/lib/pulpcore_client/models/{task_cancel.rb → patched_task_cancel.rb} +6 -29
  131. data/lib/pulpcore_client/models/permission_response.rb +235 -0
  132. data/lib/pulpcore_client/models/{progress_report.rb → progress_report_response.rb} +6 -65
  133. data/lib/pulpcore_client/models/pulp_export.rb +50 -42
  134. data/lib/pulpcore_client/models/pulp_export_response.rb +260 -0
  135. data/lib/pulpcore_client/models/pulp_exporter.rb +4 -60
  136. data/lib/pulpcore_client/models/pulp_exporter_response.rb +274 -0
  137. data/lib/pulpcore_client/models/pulp_import.rb +17 -30
  138. data/lib/pulpcore_client/models/pulp_importer.rb +6 -45
  139. data/lib/pulpcore_client/models/pulp_importer_response.rb +242 -0
  140. data/lib/pulpcore_client/models/{redis_connection.rb → redis_connection_response.rb} +6 -6
  141. data/lib/pulpcore_client/models/{signing_service.rb → signing_service_response.rb} +6 -43
  142. data/lib/pulpcore_client/models/{status.rb → status_response.rb} +15 -11
  143. data/lib/pulpcore_client/models/{storage.rb → storage_response.rb} +6 -6
  144. data/lib/pulpcore_client/models/{task_group.rb → task_group_response.rb} +7 -25
  145. data/lib/pulpcore_client/models/{task.rb → task_response.rb} +13 -59
  146. data/lib/pulpcore_client/models/upload.rb +7 -35
  147. data/lib/pulpcore_client/models/upload_chunk.rb +11 -39
  148. data/lib/pulpcore_client/models/upload_chunk_response.rb +215 -0
  149. data/lib/pulpcore_client/models/upload_commit.rb +2 -21
  150. data/lib/pulpcore_client/models/{upload_detail.rb → upload_detail_response.rb} +7 -6
  151. data/lib/pulpcore_client/models/upload_response.rb +242 -0
  152. data/lib/pulpcore_client/models/user_group_response.rb +241 -0
  153. data/lib/pulpcore_client/models/user_response.rb +378 -0
  154. data/lib/pulpcore_client/models/{version.rb → version_response.rb} +6 -44
  155. data/lib/pulpcore_client/models/{worker.rb → worker_response.rb} +6 -21
  156. data/lib/pulpcore_client/version.rb +3 -3
  157. data/lib/pulpcore_client.rb +47 -17
  158. data/pulpcore_client.gemspec +4 -4
  159. data/spec/api/access_policies_api_spec.rb +91 -0
  160. data/spec/api/artifacts_api_spec.rb +18 -15
  161. data/spec/api/exporters_core_exports_api_spec.rb +10 -10
  162. data/spec/api/exporters_pulp_api_spec.rb +18 -18
  163. data/spec/api/groups_api_spec.rb +115 -0
  164. data/spec/api/groups_model_permissions_api_spec.rb +64 -0
  165. data/spec/api/groups_object_permissions_api_spec.rb +92 -0
  166. data/spec/api/groups_users_api_spec.rb +77 -0
  167. data/spec/api/importers_core_imports_api_spec.rb +10 -10
  168. data/spec/api/importers_pulp_api_spec.rb +18 -18
  169. data/spec/api/orphans_api_spec.rb +2 -2
  170. data/spec/api/signing_services_api_spec.rb +7 -7
  171. data/spec/api/status_api_spec.rb +5 -7
  172. data/spec/api/task_groups_api_spec.rb +8 -6
  173. data/spec/api/tasks_api_spec.rb +69 -42
  174. data/spec/api/uploads_api_spec.rb +14 -13
  175. data/spec/api/users_api_spec.rb +78 -0
  176. data/spec/api/workers_api_spec.rb +18 -16
  177. data/spec/api_client_spec.rb +2 -2
  178. data/spec/configuration_spec.rb +2 -2
  179. data/spec/models/access_policy_response_spec.rb +65 -0
  180. data/spec/models/access_policy_spec.rb +53 -0
  181. data/spec/models/artifact_response_spec.rb +95 -0
  182. data/spec/models/artifact_spec.rb +2 -14
  183. data/spec/models/async_operation_response_spec.rb +2 -2
  184. data/spec/models/{content_app_status_spec.rb → content_app_status_response_spec.rb} +8 -8
  185. data/spec/models/{database_connection_spec.rb → database_connection_response_spec.rb} +8 -8
  186. data/spec/models/{group_progress_report_spec.rb → group_progress_report_response_spec.rb} +8 -8
  187. data/spec/models/group_response_spec.rb +53 -0
  188. data/spec/models/group_spec.rb +41 -0
  189. data/spec/models/group_user_response_spec.rb +47 -0
  190. data/spec/models/group_user_spec.rb +41 -0
  191. data/spec/models/{import_spec.rb → import_response_spec.rb} +8 -8
  192. data/spec/models/inline_response20010_spec.rb +59 -0
  193. data/spec/models/inline_response20011_spec.rb +59 -0
  194. data/spec/models/inline_response20012_spec.rb +59 -0
  195. data/spec/models/inline_response20013_spec.rb +59 -0
  196. data/spec/models/inline_response20014_spec.rb +59 -0
  197. data/spec/models/inline_response2001_spec.rb +2 -2
  198. data/spec/models/inline_response2002_spec.rb +2 -2
  199. data/spec/models/inline_response2003_spec.rb +2 -2
  200. data/spec/models/inline_response2004_spec.rb +2 -2
  201. data/spec/models/inline_response2005_spec.rb +2 -2
  202. data/spec/models/inline_response2006_spec.rb +2 -2
  203. data/spec/models/inline_response2007_spec.rb +2 -2
  204. data/spec/models/inline_response2008_spec.rb +2 -2
  205. data/spec/models/inline_response2009_spec.rb +2 -2
  206. data/spec/models/inline_response200_spec.rb +2 -2
  207. data/spec/models/patched_access_policy_spec.rb +53 -0
  208. data/spec/models/patched_group_spec.rb +41 -0
  209. data/spec/models/patched_pulp_exporter_spec.rb +59 -0
  210. data/spec/models/patched_pulp_importer_spec.rb +47 -0
  211. data/spec/models/{task_cancel_spec.rb → patched_task_cancel_spec.rb} +8 -8
  212. data/spec/models/permission_response_spec.rb +59 -0
  213. data/spec/models/{progress_report_spec.rb → progress_report_response_spec.rb} +8 -8
  214. data/spec/models/pulp_export_response_spec.rb +71 -0
  215. data/spec/models/pulp_export_spec.rb +8 -8
  216. data/spec/models/pulp_exporter_response_spec.rb +71 -0
  217. data/spec/models/pulp_exporter_spec.rb +2 -14
  218. data/spec/models/pulp_import_spec.rb +8 -2
  219. data/spec/models/pulp_importer_response_spec.rb +59 -0
  220. data/spec/models/pulp_importer_spec.rb +2 -14
  221. data/spec/models/{redis_connection_spec.rb → redis_connection_response_spec.rb} +8 -8
  222. data/spec/models/{signing_service_spec.rb → signing_service_response_spec.rb} +8 -8
  223. data/spec/models/{status_spec.rb → status_response_spec.rb} +8 -8
  224. data/spec/models/{storage_spec.rb → storage_response_spec.rb} +8 -8
  225. data/spec/models/{task_group_spec.rb → task_group_response_spec.rb} +8 -8
  226. data/spec/models/{task_spec.rb → task_response_spec.rb} +8 -14
  227. data/spec/models/upload_chunk_response_spec.rb +47 -0
  228. data/spec/models/upload_chunk_spec.rb +2 -14
  229. data/spec/models/upload_commit_spec.rb +2 -2
  230. data/spec/models/{upload_detail_spec.rb → upload_detail_response_spec.rb} +8 -8
  231. data/spec/models/upload_response_spec.rb +59 -0
  232. data/spec/models/upload_spec.rb +2 -20
  233. data/spec/models/user_group_response_spec.rb +47 -0
  234. data/spec/models/user_response_spec.rb +95 -0
  235. data/spec/models/{version_spec.rb → version_response_spec.rb} +8 -8
  236. data/spec/models/{worker_spec.rb → worker_response_spec.rb} +8 -8
  237. data/spec/spec_helper.rb +2 -2
  238. metadata +204 -84
  239. data/docs/Status.md +0 -27
@@ -1,10 +1,10 @@
1
1
  =begin
2
2
  #Pulp 3 API
3
3
 
4
- #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
4
+ #Fetch, Upload, Organize, and Distribute Software Packages
5
5
 
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
9
  OpenAPI Generator version: 4.2.3
10
10
 
@@ -13,45 +13,47 @@ OpenAPI Generator version: 4.2.3
13
13
  require 'date'
14
14
 
15
15
  module PulpcoreClient
16
+ # Serializer for PulpExports.
16
17
  class PulpExport
17
- attr_accessor :pulp_href
18
-
19
- # Timestamp of creation.
20
- attr_accessor :pulp_created
21
-
22
18
  # A URI of the task that ran the Export.
23
19
  attr_accessor :task
24
20
 
25
- # Resources that were exported.
26
- attr_accessor :exported_resources
21
+ # Do a Full (true) or Incremental (false) export.
22
+ attr_accessor :full
27
23
 
28
- # Any additional parameters that were used to create the export.
29
- attr_accessor :params
24
+ # Generate report on what would be exported and disk-space required.
25
+ attr_accessor :dry_run
30
26
 
31
- # Dictionary of filename: sha256hash entries for export-output-file(s)
32
- attr_accessor :output_file_info
27
+ # List of explicit repo-version hrefs to export (replaces current_version).
28
+ attr_accessor :versions
29
+
30
+ # Chunk export-tarfile into pieces of chunk_size bytes.Recognizes units of B/KB/MB/GB/TB.
31
+ attr_accessor :chunk_size
32
+
33
+ # List of explicit last-exported-repo-version hrefs (replaces last_export).
34
+ attr_accessor :start_versions
33
35
 
34
36
  # Attribute mapping from ruby-style variable name to JSON key.
35
37
  def self.attribute_map
36
38
  {
37
- :'pulp_href' => :'pulp_href',
38
- :'pulp_created' => :'pulp_created',
39
39
  :'task' => :'task',
40
- :'exported_resources' => :'exported_resources',
41
- :'params' => :'params',
42
- :'output_file_info' => :'output_file_info'
40
+ :'full' => :'full',
41
+ :'dry_run' => :'dry_run',
42
+ :'versions' => :'versions',
43
+ :'chunk_size' => :'chunk_size',
44
+ :'start_versions' => :'start_versions'
43
45
  }
44
46
  end
45
47
 
46
48
  # Attribute type mapping.
47
49
  def self.openapi_types
48
50
  {
49
- :'pulp_href' => :'String',
50
- :'pulp_created' => :'DateTime',
51
51
  :'task' => :'String',
52
- :'exported_resources' => :'Array<Object>',
53
- :'params' => :'Object',
54
- :'output_file_info' => :'Object'
52
+ :'full' => :'Boolean',
53
+ :'dry_run' => :'Boolean',
54
+ :'versions' => :'Array<String>',
55
+ :'chunk_size' => :'String',
56
+ :'start_versions' => :'Array<String>'
55
57
  }
56
58
  end
57
59
 
@@ -77,30 +79,36 @@ module PulpcoreClient
77
79
  h[k.to_sym] = v
78
80
  }
79
81
 
80
- if attributes.key?(:'pulp_href')
81
- self.pulp_href = attributes[:'pulp_href']
82
+ if attributes.key?(:'task')
83
+ self.task = attributes[:'task']
82
84
  end
83
85
 
84
- if attributes.key?(:'pulp_created')
85
- self.pulp_created = attributes[:'pulp_created']
86
+ if attributes.key?(:'full')
87
+ self.full = attributes[:'full']
88
+ else
89
+ self.full = true
86
90
  end
87
91
 
88
- if attributes.key?(:'task')
89
- self.task = attributes[:'task']
92
+ if attributes.key?(:'dry_run')
93
+ self.dry_run = attributes[:'dry_run']
94
+ else
95
+ self.dry_run = false
90
96
  end
91
97
 
92
- if attributes.key?(:'exported_resources')
93
- if (value = attributes[:'exported_resources']).is_a?(Array)
94
- self.exported_resources = value
98
+ if attributes.key?(:'versions')
99
+ if (value = attributes[:'versions']).is_a?(Array)
100
+ self.versions = value
95
101
  end
96
102
  end
97
103
 
98
- if attributes.key?(:'params')
99
- self.params = attributes[:'params']
104
+ if attributes.key?(:'chunk_size')
105
+ self.chunk_size = attributes[:'chunk_size']
100
106
  end
101
107
 
102
- if attributes.key?(:'output_file_info')
103
- self.output_file_info = attributes[:'output_file_info']
108
+ if attributes.key?(:'start_versions')
109
+ if (value = attributes[:'start_versions']).is_a?(Array)
110
+ self.start_versions = value
111
+ end
104
112
  end
105
113
  end
106
114
 
@@ -122,12 +130,12 @@ module PulpcoreClient
122
130
  def ==(o)
123
131
  return true if self.equal?(o)
124
132
  self.class == o.class &&
125
- pulp_href == o.pulp_href &&
126
- pulp_created == o.pulp_created &&
127
133
  task == o.task &&
128
- exported_resources == o.exported_resources &&
129
- params == o.params &&
130
- output_file_info == o.output_file_info
134
+ full == o.full &&
135
+ dry_run == o.dry_run &&
136
+ versions == o.versions &&
137
+ chunk_size == o.chunk_size &&
138
+ start_versions == o.start_versions
131
139
  end
132
140
 
133
141
  # @see the `==` method
@@ -139,7 +147,7 @@ module PulpcoreClient
139
147
  # Calculates hash code according to all attributes.
140
148
  # @return [Integer] Hash code
141
149
  def hash
142
- [pulp_href, pulp_created, task, exported_resources, params, output_file_info].hash
150
+ [task, full, dry_run, versions, chunk_size, start_versions].hash
143
151
  end
144
152
 
145
153
  # Builds the object from hash
@@ -0,0 +1,260 @@
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.2.3
10
+
11
+ =end
12
+
13
+ require 'date'
14
+
15
+ module PulpcoreClient
16
+ # Serializer for PulpExports.
17
+ class PulpExportResponse
18
+ attr_accessor :pulp_href
19
+
20
+ # Timestamp of creation.
21
+ attr_accessor :pulp_created
22
+
23
+ # A URI of the task that ran the Export.
24
+ attr_accessor :task
25
+
26
+ # Resources that were exported.
27
+ attr_accessor :exported_resources
28
+
29
+ # Any additional parameters that were used to create the export.
30
+ attr_accessor :params
31
+
32
+ # Dictionary of filename: sha256hash entries for export-output-file(s)
33
+ attr_accessor :output_file_info
34
+
35
+ # Attribute mapping from ruby-style variable name to JSON key.
36
+ def self.attribute_map
37
+ {
38
+ :'pulp_href' => :'pulp_href',
39
+ :'pulp_created' => :'pulp_created',
40
+ :'task' => :'task',
41
+ :'exported_resources' => :'exported_resources',
42
+ :'params' => :'params',
43
+ :'output_file_info' => :'output_file_info'
44
+ }
45
+ end
46
+
47
+ # Attribute type mapping.
48
+ def self.openapi_types
49
+ {
50
+ :'pulp_href' => :'String',
51
+ :'pulp_created' => :'DateTime',
52
+ :'task' => :'String',
53
+ :'exported_resources' => :'Array<Object>',
54
+ :'params' => :'Object',
55
+ :'output_file_info' => :'Object'
56
+ }
57
+ end
58
+
59
+ # List of attributes with nullable: true
60
+ def self.openapi_nullable
61
+ Set.new([
62
+ :'task',
63
+ ])
64
+ end
65
+
66
+ # Initializes the object
67
+ # @param [Hash] attributes Model attributes in the form of hash
68
+ def initialize(attributes = {})
69
+ if (!attributes.is_a?(Hash))
70
+ fail ArgumentError, "The input argument (attributes) must be a hash in `PulpcoreClient::PulpExportResponse` initialize method"
71
+ end
72
+
73
+ # check to see if the attribute exists and convert string to symbol for hash key
74
+ attributes = attributes.each_with_object({}) { |(k, v), h|
75
+ if (!self.class.attribute_map.key?(k.to_sym))
76
+ fail ArgumentError, "`#{k}` is not a valid attribute in `PulpcoreClient::PulpExportResponse`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
77
+ end
78
+ h[k.to_sym] = v
79
+ }
80
+
81
+ if attributes.key?(:'pulp_href')
82
+ self.pulp_href = attributes[:'pulp_href']
83
+ end
84
+
85
+ if attributes.key?(:'pulp_created')
86
+ self.pulp_created = attributes[:'pulp_created']
87
+ end
88
+
89
+ if attributes.key?(:'task')
90
+ self.task = attributes[:'task']
91
+ end
92
+
93
+ if attributes.key?(:'exported_resources')
94
+ if (value = attributes[:'exported_resources']).is_a?(Array)
95
+ self.exported_resources = value
96
+ end
97
+ end
98
+
99
+ if attributes.key?(:'params')
100
+ self.params = attributes[:'params']
101
+ end
102
+
103
+ if attributes.key?(:'output_file_info')
104
+ self.output_file_info = attributes[:'output_file_info']
105
+ end
106
+ end
107
+
108
+ # Show invalid properties with the reasons. Usually used together with valid?
109
+ # @return Array for valid properties with the reasons
110
+ def list_invalid_properties
111
+ invalid_properties = Array.new
112
+ invalid_properties
113
+ end
114
+
115
+ # Check to see if the all the properties in the model are valid
116
+ # @return true if the model is valid
117
+ def valid?
118
+ true
119
+ end
120
+
121
+ # Checks equality by comparing each attribute.
122
+ # @param [Object] Object to be compared
123
+ def ==(o)
124
+ return true if self.equal?(o)
125
+ self.class == o.class &&
126
+ pulp_href == o.pulp_href &&
127
+ pulp_created == o.pulp_created &&
128
+ task == o.task &&
129
+ exported_resources == o.exported_resources &&
130
+ params == o.params &&
131
+ output_file_info == o.output_file_info
132
+ end
133
+
134
+ # @see the `==` method
135
+ # @param [Object] Object to be compared
136
+ def eql?(o)
137
+ self == o
138
+ end
139
+
140
+ # Calculates hash code according to all attributes.
141
+ # @return [Integer] Hash code
142
+ def hash
143
+ [pulp_href, pulp_created, task, exported_resources, params, output_file_info].hash
144
+ end
145
+
146
+ # Builds the object from hash
147
+ # @param [Hash] attributes Model attributes in the form of hash
148
+ # @return [Object] Returns the model itself
149
+ def self.build_from_hash(attributes)
150
+ new.build_from_hash(attributes)
151
+ end
152
+
153
+ # Builds the object from hash
154
+ # @param [Hash] attributes Model attributes in the form of hash
155
+ # @return [Object] Returns the model itself
156
+ def build_from_hash(attributes)
157
+ return nil unless attributes.is_a?(Hash)
158
+ self.class.openapi_types.each_pair do |key, type|
159
+ if type =~ /\AArray<(.*)>/i
160
+ # check to ensure the input is an array given that the attribute
161
+ # is documented as an array but the input is not
162
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
163
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
164
+ end
165
+ elsif !attributes[self.class.attribute_map[key]].nil?
166
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
167
+ end # or else data not found in attributes(hash), not an issue as the data can be optional
168
+ end
169
+
170
+ self
171
+ end
172
+
173
+ # Deserializes the data based on type
174
+ # @param string type Data type
175
+ # @param string value Value to be deserialized
176
+ # @return [Object] Deserialized data
177
+ def _deserialize(type, value)
178
+ case type.to_sym
179
+ when :DateTime
180
+ DateTime.parse(value)
181
+ when :Date
182
+ Date.parse(value)
183
+ when :String
184
+ value.to_s
185
+ when :Integer
186
+ value.to_i
187
+ when :Float
188
+ value.to_f
189
+ when :Boolean
190
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
191
+ true
192
+ else
193
+ false
194
+ end
195
+ when :Object
196
+ # generic object (usually a Hash), return directly
197
+ value
198
+ when /\AArray<(?<inner_type>.+)>\z/
199
+ inner_type = Regexp.last_match[:inner_type]
200
+ value.map { |v| _deserialize(inner_type, v) }
201
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
202
+ k_type = Regexp.last_match[:k_type]
203
+ v_type = Regexp.last_match[:v_type]
204
+ {}.tap do |hash|
205
+ value.each do |k, v|
206
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
207
+ end
208
+ end
209
+ else # model
210
+ PulpcoreClient.const_get(type).build_from_hash(value)
211
+ end
212
+ end
213
+
214
+ # Returns the string representation of the object
215
+ # @return [String] String presentation of the object
216
+ def to_s
217
+ to_hash.to_s
218
+ end
219
+
220
+ # to_body is an alias to to_hash (backward compatibility)
221
+ # @return [Hash] Returns the object in the form of hash
222
+ def to_body
223
+ to_hash
224
+ end
225
+
226
+ # Returns the object in the form of hash
227
+ # @return [Hash] Returns the object in the form of hash
228
+ def to_hash
229
+ hash = {}
230
+ self.class.attribute_map.each_pair do |attr, param|
231
+ value = self.send(attr)
232
+ if value.nil?
233
+ is_nullable = self.class.openapi_nullable.include?(attr)
234
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
235
+ end
236
+
237
+ hash[param] = _to_hash(value)
238
+ end
239
+ hash
240
+ end
241
+
242
+ # Outputs non-array value in the form of hash
243
+ # For object, use to_hash. Otherwise, just return the value
244
+ # @param [Object] value Any valid value
245
+ # @return [Hash] Returns the value in the form of hash
246
+ def _to_hash(value)
247
+ if value.is_a?(Array)
248
+ value.compact.map { |v| _to_hash(v) }
249
+ elsif value.is_a?(Hash)
250
+ {}.tap do |hash|
251
+ value.each { |k, v| hash[k] = _to_hash(v) }
252
+ end
253
+ elsif value.respond_to? :to_hash
254
+ value.to_hash
255
+ else
256
+ value
257
+ end
258
+ end
259
+ end
260
+ end
@@ -1,10 +1,10 @@
1
1
  =begin
2
2
  #Pulp 3 API
3
3
 
4
- #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
4
+ #Fetch, Upload, Organize, and Distribute Software Packages
5
5
 
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
9
  OpenAPI Generator version: 4.2.3
10
10
 
@@ -13,12 +13,8 @@ OpenAPI Generator version: 4.2.3
13
13
  require 'date'
14
14
 
15
15
  module PulpcoreClient
16
+ # Serializer for pulp exporters.
16
17
  class PulpExporter
17
- attr_accessor :pulp_href
18
-
19
- # Timestamp of creation.
20
- attr_accessor :pulp_created
21
-
22
18
  # Unique name of the file system exporter.
23
19
  attr_accessor :name
24
20
 
@@ -33,8 +29,6 @@ module PulpcoreClient
33
29
  # Attribute mapping from ruby-style variable name to JSON key.
34
30
  def self.attribute_map
35
31
  {
36
- :'pulp_href' => :'pulp_href',
37
- :'pulp_created' => :'pulp_created',
38
32
  :'name' => :'name',
39
33
  :'path' => :'path',
40
34
  :'repositories' => :'repositories',
@@ -45,8 +39,6 @@ module PulpcoreClient
45
39
  # Attribute type mapping.
46
40
  def self.openapi_types
47
41
  {
48
- :'pulp_href' => :'String',
49
- :'pulp_created' => :'DateTime',
50
42
  :'name' => :'String',
51
43
  :'path' => :'String',
52
44
  :'repositories' => :'Array<String>',
@@ -76,14 +68,6 @@ module PulpcoreClient
76
68
  h[k.to_sym] = v
77
69
  }
78
70
 
79
- if attributes.key?(:'pulp_href')
80
- self.pulp_href = attributes[:'pulp_href']
81
- end
82
-
83
- if attributes.key?(:'pulp_created')
84
- self.pulp_created = attributes[:'pulp_created']
85
- end
86
-
87
71
  if attributes.key?(:'name')
88
72
  self.name = attributes[:'name']
89
73
  end
@@ -111,18 +95,10 @@ module PulpcoreClient
111
95
  invalid_properties.push('invalid value for "name", name cannot be nil.')
112
96
  end
113
97
 
114
- if @name.to_s.length < 1
115
- invalid_properties.push('invalid value for "name", the character length must be great than or equal to 1.')
116
- end
117
-
118
98
  if @path.nil?
119
99
  invalid_properties.push('invalid value for "path", path cannot be nil.')
120
100
  end
121
101
 
122
- if @path.to_s.length < 1
123
- invalid_properties.push('invalid value for "path", the character length must be great than or equal to 1.')
124
- end
125
-
126
102
  if @repositories.nil?
127
103
  invalid_properties.push('invalid value for "repositories", repositories cannot be nil.')
128
104
  end
@@ -134,48 +110,16 @@ module PulpcoreClient
134
110
  # @return true if the model is valid
135
111
  def valid?
136
112
  return false if @name.nil?
137
- return false if @name.to_s.length < 1
138
113
  return false if @path.nil?
139
- return false if @path.to_s.length < 1
140
114
  return false if @repositories.nil?
141
115
  true
142
116
  end
143
117
 
144
- # Custom attribute writer method with validation
145
- # @param [Object] name Value to be assigned
146
- def name=(name)
147
- if name.nil?
148
- fail ArgumentError, 'name cannot be nil'
149
- end
150
-
151
- if name.to_s.length < 1
152
- fail ArgumentError, 'invalid value for "name", the character length must be great than or equal to 1.'
153
- end
154
-
155
- @name = name
156
- end
157
-
158
- # Custom attribute writer method with validation
159
- # @param [Object] path Value to be assigned
160
- def path=(path)
161
- if path.nil?
162
- fail ArgumentError, 'path cannot be nil'
163
- end
164
-
165
- if path.to_s.length < 1
166
- fail ArgumentError, 'invalid value for "path", the character length must be great than or equal to 1.'
167
- end
168
-
169
- @path = path
170
- end
171
-
172
118
  # Checks equality by comparing each attribute.
173
119
  # @param [Object] Object to be compared
174
120
  def ==(o)
175
121
  return true if self.equal?(o)
176
122
  self.class == o.class &&
177
- pulp_href == o.pulp_href &&
178
- pulp_created == o.pulp_created &&
179
123
  name == o.name &&
180
124
  path == o.path &&
181
125
  repositories == o.repositories &&
@@ -191,7 +135,7 @@ module PulpcoreClient
191
135
  # Calculates hash code according to all attributes.
192
136
  # @return [Integer] Hash code
193
137
  def hash
194
- [pulp_href, pulp_created, name, path, repositories, last_export].hash
138
+ [name, path, repositories, last_export].hash
195
139
  end
196
140
 
197
141
  # Builds the object from hash