pulp_deb_client 3.4.0 → 3.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +34 -9
- data/docs/AptRepositorySyncURL.md +12 -11
- data/docs/AsyncOperationResponse.md +8 -7
- data/docs/ContentGenericContentsApi.md +114 -64
- data/docs/ContentInstallerFileIndicesApi.md +111 -61
- data/docs/ContentInstallerPackagesApi.md +130 -80
- data/docs/ContentPackageIndicesApi.md +111 -61
- data/docs/ContentPackageReleaseComponentsApi.md +111 -61
- data/docs/ContentPackagesApi.md +144 -94
- data/docs/ContentReleaseArchitecturesApi.md +109 -59
- data/docs/ContentReleaseComponentsApi.md +110 -60
- data/docs/ContentReleaseFilesApi.md +111 -61
- data/docs/ContentReleasesApi.md +114 -64
- data/docs/ContentSourceIndicesApi.md +110 -60
- data/docs/ContentSourcePackagesApi.md +137 -87
- data/docs/ContentSourceReleaseComponentsApi.md +111 -61
- data/docs/ContentSummaryResponse.md +12 -11
- data/docs/Copy.md +12 -11
- data/docs/DebAptDistribution.md +20 -19
- data/docs/DebAptDistributionResponse.md +32 -31
- data/docs/DebAptPublication.md +18 -17
- data/docs/DebAptPublicationResponse.md +26 -25
- data/docs/DebAptRemote.md +64 -63
- data/docs/DebAptRemoteResponse.md +64 -63
- data/docs/DebAptRemoteResponseHiddenFieldsInner.md +20 -0
- data/docs/DebAptRepository.md +22 -21
- data/docs/DebAptRepositoryResponse.md +34 -33
- data/docs/DebCopyApi.md +30 -14
- data/docs/DebGenericContentResponse.md +30 -29
- data/docs/DebInstallerFileIndex.md +16 -15
- data/docs/DebInstallerFileIndexResponse.md +22 -21
- data/docs/DebInstallerPackageResponse.md +88 -87
- data/docs/DebPackageIndex.md +16 -15
- data/docs/DebPackageIndexResponse.md +22 -21
- data/docs/DebPackageReleaseComponent.md +12 -11
- data/docs/DebPackageReleaseComponentResponse.md +18 -17
- data/docs/DebPackageResponse.md +92 -91
- data/docs/DebRelease.md +26 -25
- data/docs/DebReleaseArchitecture.md +12 -11
- data/docs/DebReleaseArchitectureResponse.md +18 -17
- data/docs/DebReleaseComponent.md +12 -11
- data/docs/DebReleaseComponentResponse.md +20 -17
- data/docs/DebReleaseFile.md +18 -17
- data/docs/DebReleaseFileResponse.md +24 -23
- data/docs/DebReleaseResponse.md +32 -31
- data/docs/DebSourceIndex.md +16 -15
- data/docs/DebSourceIndexResponse.md +22 -21
- data/docs/DebSourcePackage.md +12 -11
- data/docs/DebSourcePackageReleaseComponent.md +12 -11
- data/docs/DebSourcePackageReleaseComponentResponse.md +18 -17
- data/docs/DebSourcePackageResponse.md +74 -71
- data/docs/DebVerbatimPublication.md +10 -9
- data/docs/DebVerbatimPublicationResponse.md +18 -17
- data/docs/DistributionsAptApi.md +564 -129
- data/docs/MyPermissionsResponse.md +18 -0
- data/docs/NestedRole.md +22 -0
- data/docs/NestedRoleResponse.md +22 -0
- data/docs/ObjectRolesResponse.md +18 -0
- data/docs/PaginatedRepositoryVersionResponseList.md +14 -13
- data/docs/PaginateddebAptDistributionResponseList.md +14 -13
- data/docs/PaginateddebAptPublicationResponseList.md +14 -13
- data/docs/PaginateddebAptRemoteResponseList.md +14 -13
- data/docs/PaginateddebAptRepositoryResponseList.md +14 -13
- data/docs/PaginateddebGenericContentResponseList.md +14 -13
- data/docs/PaginateddebInstallerFileIndexResponseList.md +14 -13
- data/docs/PaginateddebInstallerPackageResponseList.md +14 -13
- data/docs/PaginateddebPackageIndexResponseList.md +14 -13
- data/docs/PaginateddebPackageReleaseComponentResponseList.md +14 -13
- data/docs/PaginateddebPackageResponseList.md +14 -13
- data/docs/PaginateddebReleaseArchitectureResponseList.md +14 -13
- data/docs/PaginateddebReleaseComponentResponseList.md +14 -13
- data/docs/PaginateddebReleaseFileResponseList.md +14 -13
- data/docs/PaginateddebReleaseResponseList.md +14 -13
- data/docs/PaginateddebSourceIndexResponseList.md +14 -13
- data/docs/PaginateddebSourcePackageReleaseComponentResponseList.md +14 -13
- data/docs/PaginateddebSourcePackageResponseList.md +14 -13
- data/docs/PaginateddebVerbatimPublicationResponseList.md +14 -13
- data/docs/PatcheddebAptDistribution.md +20 -19
- data/docs/PatcheddebAptRemote.md +64 -63
- data/docs/PatcheddebAptRepository.md +22 -21
- data/docs/PolicyEnum.md +4 -5
- data/docs/PublicationsAptApi.md +446 -77
- data/docs/PublicationsVerbatimApi.md +446 -77
- data/docs/RemotesAptApi.md +568 -131
- data/docs/Repair.md +8 -7
- data/docs/RepositoriesAptApi.md +623 -154
- data/docs/RepositoriesAptVersionsApi.md +152 -82
- data/docs/RepositoryAddRemoveContent.md +12 -11
- data/docs/RepositoryVersionResponse.md +22 -21
- data/docs/SetLabel.md +10 -9
- data/docs/SetLabelResponse.md +10 -9
- data/docs/UnsetLabel.md +8 -7
- data/docs/UnsetLabelResponse.md +10 -9
- data/lib/pulp_deb_client/api/content_generic_contents_api.rb +20 -14
- data/lib/pulp_deb_client/api/content_installer_file_indices_api.rb +20 -14
- data/lib/pulp_deb_client/api/content_installer_packages_api.rb +20 -22
- data/lib/pulp_deb_client/api/content_package_indices_api.rb +20 -14
- data/lib/pulp_deb_client/api/content_package_release_components_api.rb +20 -14
- data/lib/pulp_deb_client/api/content_packages_api.rb +20 -22
- data/lib/pulp_deb_client/api/content_release_architectures_api.rb +20 -14
- data/lib/pulp_deb_client/api/content_release_components_api.rb +20 -14
- data/lib/pulp_deb_client/api/content_release_files_api.rb +20 -14
- data/lib/pulp_deb_client/api/content_releases_api.rb +20 -14
- data/lib/pulp_deb_client/api/content_source_indices_api.rb +20 -14
- data/lib/pulp_deb_client/api/content_source_packages_api.rb +20 -14
- data/lib/pulp_deb_client/api/content_source_release_components_api.rb +20 -14
- data/lib/pulp_deb_client/api/deb_copy_api.rb +10 -6
- data/lib/pulp_deb_client/api/distributions_apt_api.rb +347 -38
- data/lib/pulp_deb_client/api/publications_apt_api.rb +325 -29
- data/lib/pulp_deb_client/api/publications_verbatim_api.rb +325 -29
- data/lib/pulp_deb_client/api/remotes_apt_api.rb +362 -50
- data/lib/pulp_deb_client/api/repositories_apt_api.rb +365 -48
- data/lib/pulp_deb_client/api/repositories_apt_versions_api.rb +40 -30
- data/lib/pulp_deb_client/api_client.rb +137 -102
- data/lib/pulp_deb_client/api_error.rb +2 -1
- data/lib/pulp_deb_client/configuration.rb +162 -21
- data/lib/pulp_deb_client/models/apt_repository_sync_url.rb +30 -22
- data/lib/pulp_deb_client/models/async_operation_response.rb +32 -22
- data/lib/pulp_deb_client/models/content_summary_response.rb +36 -22
- data/lib/pulp_deb_client/models/copy.rb +34 -28
- data/lib/pulp_deb_client/models/deb_apt_distribution.rb +34 -22
- data/lib/pulp_deb_client/models/deb_apt_distribution_response.rb +36 -24
- data/lib/pulp_deb_client/models/deb_apt_publication.rb +30 -22
- data/lib/pulp_deb_client/models/deb_apt_publication_response.rb +32 -24
- data/lib/pulp_deb_client/models/deb_apt_remote.rb +78 -42
- data/lib/pulp_deb_client/models/deb_apt_remote_response.rb +81 -45
- data/lib/pulp_deb_client/models/{deb_apt_remote_response_hidden_fields.rb → deb_apt_remote_response_hidden_fields_inner.rb} +37 -25
- data/lib/pulp_deb_client/models/deb_apt_repository.rb +32 -22
- data/lib/pulp_deb_client/models/deb_apt_repository_response.rb +34 -24
- data/lib/pulp_deb_client/models/deb_generic_content_response.rb +34 -24
- data/lib/pulp_deb_client/models/deb_installer_file_index.rb +41 -23
- data/lib/pulp_deb_client/models/deb_installer_file_index_response.rb +38 -24
- data/lib/pulp_deb_client/models/deb_installer_package_response.rb +32 -24
- data/lib/pulp_deb_client/models/deb_package_index.rb +47 -25
- data/lib/pulp_deb_client/models/deb_package_index_response.rb +34 -24
- data/lib/pulp_deb_client/models/deb_package_release_component.rb +34 -22
- data/lib/pulp_deb_client/models/deb_package_release_component_response.rb +36 -24
- data/lib/pulp_deb_client/models/deb_package_response.rb +32 -24
- data/lib/pulp_deb_client/models/deb_release.rb +36 -22
- data/lib/pulp_deb_client/models/deb_release_architecture.rb +34 -22
- data/lib/pulp_deb_client/models/deb_release_architecture_response.rb +36 -24
- data/lib/pulp_deb_client/models/deb_release_component.rb +34 -22
- data/lib/pulp_deb_client/models/deb_release_component_response.rb +50 -28
- data/lib/pulp_deb_client/models/deb_release_file.rb +49 -25
- data/lib/pulp_deb_client/models/deb_release_file_response.rb +36 -24
- data/lib/pulp_deb_client/models/deb_release_response.rb +38 -24
- data/lib/pulp_deb_client/models/deb_source_index.rb +41 -23
- data/lib/pulp_deb_client/models/deb_source_index_response.rb +38 -24
- data/lib/pulp_deb_client/models/deb_source_package.rb +37 -23
- data/lib/pulp_deb_client/models/deb_source_package_release_component.rb +34 -22
- data/lib/pulp_deb_client/models/deb_source_package_release_component_response.rb +36 -24
- data/lib/pulp_deb_client/models/deb_source_package_response.rb +45 -25
- data/lib/pulp_deb_client/models/deb_verbatim_publication.rb +30 -22
- data/lib/pulp_deb_client/models/deb_verbatim_publication_response.rb +32 -24
- data/lib/pulp_deb_client/models/my_permissions_response.rb +223 -0
- data/lib/pulp_deb_client/models/{deb_installer_package.rb → nested_role.rb} +72 -97
- data/lib/pulp_deb_client/models/{deb_generic_content.rb → nested_role_response.rb} +62 -115
- data/lib/pulp_deb_client/models/object_roles_response.rb +223 -0
- data/lib/pulp_deb_client/models/paginated_repository_version_response_list.rb +34 -22
- data/lib/pulp_deb_client/models/paginateddeb_apt_distribution_response_list.rb +34 -22
- data/lib/pulp_deb_client/models/paginateddeb_apt_publication_response_list.rb +34 -22
- data/lib/pulp_deb_client/models/paginateddeb_apt_remote_response_list.rb +34 -22
- data/lib/pulp_deb_client/models/paginateddeb_apt_repository_response_list.rb +34 -22
- data/lib/pulp_deb_client/models/paginateddeb_generic_content_response_list.rb +34 -22
- data/lib/pulp_deb_client/models/paginateddeb_installer_file_index_response_list.rb +34 -22
- data/lib/pulp_deb_client/models/paginateddeb_installer_package_response_list.rb +34 -22
- data/lib/pulp_deb_client/models/paginateddeb_package_index_response_list.rb +34 -22
- data/lib/pulp_deb_client/models/paginateddeb_package_release_component_response_list.rb +34 -22
- data/lib/pulp_deb_client/models/paginateddeb_package_response_list.rb +34 -22
- data/lib/pulp_deb_client/models/paginateddeb_release_architecture_response_list.rb +34 -22
- data/lib/pulp_deb_client/models/paginateddeb_release_component_response_list.rb +34 -22
- data/lib/pulp_deb_client/models/paginateddeb_release_file_response_list.rb +34 -22
- data/lib/pulp_deb_client/models/paginateddeb_release_response_list.rb +34 -22
- data/lib/pulp_deb_client/models/paginateddeb_source_index_response_list.rb +34 -22
- data/lib/pulp_deb_client/models/paginateddeb_source_package_release_component_response_list.rb +34 -22
- data/lib/pulp_deb_client/models/paginateddeb_source_package_response_list.rb +34 -22
- data/lib/pulp_deb_client/models/paginateddeb_verbatim_publication_response_list.rb +34 -22
- data/lib/pulp_deb_client/models/patcheddeb_apt_distribution.rb +40 -24
- data/lib/pulp_deb_client/models/patcheddeb_apt_remote.rb +87 -45
- data/lib/pulp_deb_client/models/patcheddeb_apt_repository.rb +35 -23
- data/lib/pulp_deb_client/models/policy_enum.rb +8 -4
- data/lib/pulp_deb_client/models/repair.rb +30 -22
- data/lib/pulp_deb_client/models/repository_add_remove_content.rb +30 -22
- data/lib/pulp_deb_client/models/repository_version_response.rb +32 -24
- data/lib/pulp_deb_client/models/set_label.rb +34 -22
- data/lib/pulp_deb_client/models/set_label_response.rb +34 -22
- data/lib/pulp_deb_client/models/unset_label.rb +32 -22
- data/lib/pulp_deb_client/models/unset_label_response.rb +32 -22
- data/lib/pulp_deb_client/version.rb +2 -2
- data/lib/pulp_deb_client.rb +6 -5
- data/pulp_deb_client.gemspec +9 -6
- data/spec/api/content_generic_contents_api_spec.rb +4 -4
- data/spec/api/content_installer_file_indices_api_spec.rb +4 -4
- data/spec/api/content_installer_packages_api_spec.rb +4 -4
- data/spec/api/content_package_indices_api_spec.rb +4 -4
- data/spec/api/content_package_release_components_api_spec.rb +4 -4
- data/spec/api/content_packages_api_spec.rb +4 -4
- data/spec/api/content_release_architectures_api_spec.rb +4 -4
- data/spec/api/content_release_components_api_spec.rb +4 -4
- data/spec/api/content_release_files_api_spec.rb +4 -4
- data/spec/api/content_releases_api_spec.rb +4 -4
- data/spec/api/content_source_indices_api_spec.rb +4 -4
- data/spec/api/content_source_packages_api_spec.rb +4 -4
- data/spec/api/content_source_release_components_api_spec.rb +4 -4
- data/spec/api/deb_copy_api_spec.rb +2 -2
- data/spec/api/distributions_apt_api_spec.rb +63 -9
- data/spec/api/publications_apt_api_spec.rb +66 -11
- data/spec/api/publications_verbatim_api_spec.rb +66 -11
- data/spec/api/remotes_apt_api_spec.rb +70 -15
- data/spec/api/repositories_apt_api_spec.rb +65 -11
- data/spec/api/repositories_apt_versions_api_spec.rb +12 -11
- data/spec/models/apt_repository_sync_url_spec.rb +9 -14
- data/spec/models/async_operation_response_spec.rb +7 -12
- data/spec/models/content_summary_response_spec.rb +9 -14
- data/spec/models/copy_spec.rb +9 -14
- data/spec/models/deb_apt_distribution_response_spec.rb +19 -24
- data/spec/models/deb_apt_distribution_spec.rb +13 -18
- data/spec/models/deb_apt_publication_response_spec.rb +16 -21
- data/spec/models/deb_apt_publication_spec.rb +12 -17
- data/spec/models/{deb_apt_remote_response_hidden_fields_spec.rb → deb_apt_remote_response_hidden_fields_inner_spec.rb} +11 -16
- data/spec/models/deb_apt_remote_response_spec.rb +35 -40
- data/spec/models/deb_apt_remote_spec.rb +35 -40
- data/spec/models/deb_apt_repository_response_spec.rb +20 -25
- data/spec/models/deb_apt_repository_spec.rb +14 -19
- data/spec/models/deb_generic_content_response_spec.rb +18 -23
- data/spec/models/deb_installer_file_index_response_spec.rb +14 -19
- data/spec/models/deb_installer_file_index_spec.rb +11 -16
- data/spec/models/deb_installer_package_response_spec.rb +47 -52
- data/spec/models/deb_package_index_response_spec.rb +14 -19
- data/spec/models/deb_package_index_spec.rb +11 -16
- data/spec/models/deb_package_release_component_response_spec.rb +12 -17
- data/spec/models/deb_package_release_component_spec.rb +9 -14
- data/spec/models/deb_package_response_spec.rb +49 -54
- data/spec/models/deb_release_architecture_response_spec.rb +12 -17
- data/spec/models/deb_release_architecture_spec.rb +9 -14
- data/spec/models/deb_release_component_response_spec.rb +18 -17
- data/spec/models/deb_release_component_spec.rb +9 -14
- data/spec/models/deb_release_file_response_spec.rb +15 -20
- data/spec/models/deb_release_file_spec.rb +12 -17
- data/spec/models/deb_release_response_spec.rb +19 -24
- data/spec/models/deb_release_spec.rb +16 -21
- data/spec/models/deb_source_index_response_spec.rb +14 -19
- data/spec/models/deb_source_index_spec.rb +11 -16
- data/spec/models/deb_source_package_release_component_response_spec.rb +12 -17
- data/spec/models/deb_source_package_release_component_spec.rb +9 -14
- data/spec/models/deb_source_package_response_spec.rb +45 -44
- data/spec/models/deb_source_package_spec.rb +9 -14
- data/spec/models/deb_verbatim_publication_response_spec.rb +12 -17
- data/spec/models/deb_verbatim_publication_spec.rb +8 -13
- data/spec/models/my_permissions_response_spec.rb +36 -0
- data/spec/models/nested_role_response_spec.rb +48 -0
- data/spec/models/nested_role_spec.rb +48 -0
- data/spec/models/object_roles_response_spec.rb +36 -0
- data/spec/models/paginated_repository_version_response_list_spec.rb +10 -15
- data/spec/models/paginateddeb_apt_distribution_response_list_spec.rb +10 -15
- data/spec/models/paginateddeb_apt_publication_response_list_spec.rb +10 -15
- data/spec/models/paginateddeb_apt_remote_response_list_spec.rb +10 -15
- data/spec/models/paginateddeb_apt_repository_response_list_spec.rb +10 -15
- data/spec/models/paginateddeb_generic_content_response_list_spec.rb +10 -15
- data/spec/models/paginateddeb_installer_file_index_response_list_spec.rb +10 -15
- data/spec/models/paginateddeb_installer_package_response_list_spec.rb +10 -15
- data/spec/models/paginateddeb_package_index_response_list_spec.rb +10 -15
- data/spec/models/paginateddeb_package_release_component_response_list_spec.rb +10 -15
- data/spec/models/paginateddeb_package_response_list_spec.rb +10 -15
- data/spec/models/paginateddeb_release_architecture_response_list_spec.rb +10 -15
- data/spec/models/paginateddeb_release_component_response_list_spec.rb +10 -15
- data/spec/models/paginateddeb_release_file_response_list_spec.rb +10 -15
- data/spec/models/paginateddeb_release_response_list_spec.rb +10 -15
- data/spec/models/paginateddeb_source_index_response_list_spec.rb +10 -15
- data/spec/models/paginateddeb_source_package_release_component_response_list_spec.rb +10 -15
- data/spec/models/paginateddeb_source_package_response_list_spec.rb +10 -15
- data/spec/models/paginateddeb_verbatim_publication_response_list_spec.rb +10 -15
- data/spec/models/patcheddeb_apt_distribution_spec.rb +13 -18
- data/spec/models/patcheddeb_apt_remote_spec.rb +35 -40
- data/spec/models/patcheddeb_apt_repository_spec.rb +14 -19
- data/spec/models/policy_enum_spec.rb +6 -11
- data/spec/models/repair_spec.rb +7 -12
- data/spec/models/repository_add_remove_content_spec.rb +9 -14
- data/spec/models/repository_version_response_spec.rb +14 -19
- data/spec/models/set_label_response_spec.rb +8 -13
- data/spec/models/set_label_spec.rb +8 -13
- data/spec/models/unset_label_response_spec.rb +8 -13
- data/spec/models/unset_label_spec.rb +7 -12
- data/spec/spec_helper.rb +1 -1
- metadata +136 -108
- data/docs/DebAptRemoteResponseHiddenFields.md +0 -19
- data/docs/DebGenericContent.md +0 -27
- data/docs/DebInstallerPackage.md +0 -27
- data/docs/DebPackage.md +0 -31
- data/lib/pulp_deb_client/models/deb_package.rb +0 -338
- data/spec/api_client_spec.rb +0 -188
- data/spec/configuration_spec.rb +0 -42
- data/spec/models/deb_generic_content_spec.rb +0 -71
- data/spec/models/deb_installer_package_spec.rb +0 -71
- data/spec/models/deb_package_spec.rb +0 -83
@@ -6,54 +6,42 @@
|
|
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
|
+
Generator version: 7.10.0
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
13
13
|
require 'date'
|
14
|
+
require 'time'
|
14
15
|
|
15
16
|
module PulpDebClient
|
16
|
-
#
|
17
|
-
class
|
18
|
-
|
19
|
-
attr_accessor :repository
|
17
|
+
# Serializer to add/remove object roles to/from users/groups. This is used in conjunction with ``pulpcore.app.viewsets.base.RolesMixin`` and requires the underlying object to be passed as ``content_object`` in the context.
|
18
|
+
class NestedRole
|
19
|
+
attr_accessor :users
|
20
20
|
|
21
|
-
|
22
|
-
attr_accessor :artifact
|
21
|
+
attr_accessor :groups
|
23
22
|
|
24
|
-
|
25
|
-
attr_accessor :relative_path
|
26
|
-
|
27
|
-
# An uploaded file that may be turned into the content unit.
|
28
|
-
attr_accessor :file
|
29
|
-
|
30
|
-
# An uncommitted upload that may be turned into the content unit.
|
31
|
-
attr_accessor :upload
|
32
|
-
|
33
|
-
# A url that Pulp can download and turn into the content unit.
|
34
|
-
attr_accessor :file_url
|
23
|
+
attr_accessor :role
|
35
24
|
|
36
25
|
# Attribute mapping from ruby-style variable name to JSON key.
|
37
26
|
def self.attribute_map
|
38
27
|
{
|
39
|
-
:'
|
40
|
-
:'
|
41
|
-
:'
|
42
|
-
:'file' => :'file',
|
43
|
-
:'upload' => :'upload',
|
44
|
-
:'file_url' => :'file_url'
|
28
|
+
:'users' => :'users',
|
29
|
+
:'groups' => :'groups',
|
30
|
+
:'role' => :'role'
|
45
31
|
}
|
46
32
|
end
|
47
33
|
|
34
|
+
# Returns all the JSON keys this model knows about
|
35
|
+
def self.acceptable_attributes
|
36
|
+
attribute_map.values
|
37
|
+
end
|
38
|
+
|
48
39
|
# Attribute type mapping.
|
49
40
|
def self.openapi_types
|
50
41
|
{
|
51
|
-
:'
|
52
|
-
:'
|
53
|
-
:'
|
54
|
-
:'file' => :'File',
|
55
|
-
:'upload' => :'String',
|
56
|
-
:'file_url' => :'String'
|
42
|
+
:'users' => :'Array<String>',
|
43
|
+
:'groups' => :'Array<String>',
|
44
|
+
:'role' => :'String'
|
57
45
|
}
|
58
46
|
end
|
59
47
|
|
@@ -67,52 +55,47 @@ module PulpDebClient
|
|
67
55
|
# @param [Hash] attributes Model attributes in the form of hash
|
68
56
|
def initialize(attributes = {})
|
69
57
|
if (!attributes.is_a?(Hash))
|
70
|
-
fail ArgumentError, "The input argument (attributes) must be a hash in `PulpDebClient::
|
58
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `PulpDebClient::NestedRole` initialize method"
|
71
59
|
end
|
72
60
|
|
73
61
|
# check to see if the attribute exists and convert string to symbol for hash key
|
74
62
|
attributes = attributes.each_with_object({}) { |(k, v), h|
|
75
63
|
if (!self.class.attribute_map.key?(k.to_sym))
|
76
|
-
fail ArgumentError, "`#{k}` is not a valid attribute in `PulpDebClient::
|
64
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `PulpDebClient::NestedRole`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
77
65
|
end
|
78
66
|
h[k.to_sym] = v
|
79
67
|
}
|
80
68
|
|
81
|
-
if attributes.key?(:'
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
if attributes.key?(:'artifact')
|
86
|
-
self.artifact = attributes[:'artifact']
|
87
|
-
end
|
88
|
-
|
89
|
-
if attributes.key?(:'relative_path')
|
90
|
-
self.relative_path = attributes[:'relative_path']
|
91
|
-
end
|
92
|
-
|
93
|
-
if attributes.key?(:'file')
|
94
|
-
self.file = attributes[:'file']
|
69
|
+
if attributes.key?(:'users')
|
70
|
+
if (value = attributes[:'users']).is_a?(Array)
|
71
|
+
self.users = value
|
72
|
+
end
|
95
73
|
end
|
96
74
|
|
97
|
-
if attributes.key?(:'
|
98
|
-
|
75
|
+
if attributes.key?(:'groups')
|
76
|
+
if (value = attributes[:'groups']).is_a?(Array)
|
77
|
+
self.groups = value
|
78
|
+
end
|
99
79
|
end
|
100
80
|
|
101
|
-
if attributes.key?(:'
|
102
|
-
self.
|
81
|
+
if attributes.key?(:'role')
|
82
|
+
self.role = attributes[:'role']
|
83
|
+
else
|
84
|
+
self.role = nil
|
103
85
|
end
|
104
86
|
end
|
105
87
|
|
106
88
|
# Show invalid properties with the reasons. Usually used together with valid?
|
107
89
|
# @return Array for valid properties with the reasons
|
108
90
|
def list_invalid_properties
|
91
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
109
92
|
invalid_properties = Array.new
|
110
|
-
if
|
111
|
-
invalid_properties.push('invalid value for "
|
93
|
+
if @role.nil?
|
94
|
+
invalid_properties.push('invalid value for "role", role cannot be nil.')
|
112
95
|
end
|
113
96
|
|
114
|
-
if
|
115
|
-
invalid_properties.push('invalid value for "
|
97
|
+
if @role.to_s.length < 1
|
98
|
+
invalid_properties.push('invalid value for "role", the character length must be great than or equal to 1.')
|
116
99
|
end
|
117
100
|
|
118
101
|
invalid_properties
|
@@ -121,29 +104,24 @@ module PulpDebClient
|
|
121
104
|
# Check to see if the all the properties in the model are valid
|
122
105
|
# @return true if the model is valid
|
123
106
|
def valid?
|
124
|
-
|
125
|
-
return false if
|
107
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
108
|
+
return false if @role.nil?
|
109
|
+
return false if @role.to_s.length < 1
|
126
110
|
true
|
127
111
|
end
|
128
112
|
|
129
113
|
# Custom attribute writer method with validation
|
130
|
-
# @param [Object]
|
131
|
-
def
|
132
|
-
if
|
133
|
-
fail ArgumentError, '
|
114
|
+
# @param [Object] role Value to be assigned
|
115
|
+
def role=(role)
|
116
|
+
if role.nil?
|
117
|
+
fail ArgumentError, 'role cannot be nil'
|
134
118
|
end
|
135
119
|
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
# Custom attribute writer method with validation
|
140
|
-
# @param [Object] file_url Value to be assigned
|
141
|
-
def file_url=(file_url)
|
142
|
-
if !file_url.nil? && file_url.to_s.length < 1
|
143
|
-
fail ArgumentError, 'invalid value for "file_url", the character length must be great than or equal to 1.'
|
120
|
+
if role.to_s.length < 1
|
121
|
+
fail ArgumentError, 'invalid value for "role", the character length must be great than or equal to 1.'
|
144
122
|
end
|
145
123
|
|
146
|
-
@
|
124
|
+
@role = role
|
147
125
|
end
|
148
126
|
|
149
127
|
# Checks equality by comparing each attribute.
|
@@ -151,12 +129,9 @@ module PulpDebClient
|
|
151
129
|
def ==(o)
|
152
130
|
return true if self.equal?(o)
|
153
131
|
self.class == o.class &&
|
154
|
-
|
155
|
-
|
156
|
-
|
157
|
-
file == o.file &&
|
158
|
-
upload == o.upload &&
|
159
|
-
file_url == o.file_url
|
132
|
+
users == o.users &&
|
133
|
+
groups == o.groups &&
|
134
|
+
role == o.role
|
160
135
|
end
|
161
136
|
|
162
137
|
# @see the `==` method
|
@@ -168,44 +143,40 @@ module PulpDebClient
|
|
168
143
|
# Calculates hash code according to all attributes.
|
169
144
|
# @return [Integer] Hash code
|
170
145
|
def hash
|
171
|
-
[
|
146
|
+
[users, groups, role].hash
|
172
147
|
end
|
173
148
|
|
174
149
|
# Builds the object from hash
|
175
150
|
# @param [Hash] attributes Model attributes in the form of hash
|
176
151
|
# @return [Object] Returns the model itself
|
177
152
|
def self.build_from_hash(attributes)
|
178
|
-
new.build_from_hash(attributes)
|
179
|
-
end
|
180
|
-
|
181
|
-
# Builds the object from hash
|
182
|
-
# @param [Hash] attributes Model attributes in the form of hash
|
183
|
-
# @return [Object] Returns the model itself
|
184
|
-
def build_from_hash(attributes)
|
185
153
|
return nil unless attributes.is_a?(Hash)
|
186
|
-
|
187
|
-
|
154
|
+
attributes = attributes.transform_keys(&:to_sym)
|
155
|
+
transformed_hash = {}
|
156
|
+
openapi_types.each_pair do |key, type|
|
157
|
+
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
158
|
+
transformed_hash["#{key}"] = nil
|
159
|
+
elsif type =~ /\AArray<(.*)>/i
|
188
160
|
# check to ensure the input is an array given that the attribute
|
189
161
|
# is documented as an array but the input is not
|
190
|
-
if attributes[
|
191
|
-
|
162
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
163
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
192
164
|
end
|
193
|
-
elsif !attributes[
|
194
|
-
|
195
|
-
end
|
165
|
+
elsif !attributes[attribute_map[key]].nil?
|
166
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
167
|
+
end
|
196
168
|
end
|
197
|
-
|
198
|
-
self
|
169
|
+
new(transformed_hash)
|
199
170
|
end
|
200
171
|
|
201
172
|
# Deserializes the data based on type
|
202
173
|
# @param string type Data type
|
203
174
|
# @param string value Value to be deserialized
|
204
175
|
# @return [Object] Deserialized data
|
205
|
-
def _deserialize(type, value)
|
176
|
+
def self._deserialize(type, value)
|
206
177
|
case type.to_sym
|
207
|
-
when :
|
208
|
-
|
178
|
+
when :Time
|
179
|
+
Time.parse(value)
|
209
180
|
when :Date
|
210
181
|
Date.parse(value)
|
211
182
|
when :String
|
@@ -235,7 +206,9 @@ module PulpDebClient
|
|
235
206
|
end
|
236
207
|
end
|
237
208
|
else # model
|
238
|
-
|
209
|
+
# models (e.g. Pet) or oneOf
|
210
|
+
klass = PulpDebClient.const_get(type)
|
211
|
+
klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
239
212
|
end
|
240
213
|
end
|
241
214
|
|
@@ -261,7 +234,7 @@ module PulpDebClient
|
|
261
234
|
is_nullable = self.class.openapi_nullable.include?(attr)
|
262
235
|
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
263
236
|
end
|
264
|
-
|
237
|
+
|
265
238
|
hash[param] = _to_hash(value)
|
266
239
|
end
|
267
240
|
hash
|
@@ -284,5 +257,7 @@ module PulpDebClient
|
|
284
257
|
value
|
285
258
|
end
|
286
259
|
end
|
260
|
+
|
287
261
|
end
|
262
|
+
|
288
263
|
end
|
@@ -6,54 +6,42 @@
|
|
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
|
+
Generator version: 7.10.0
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
13
13
|
require 'date'
|
14
|
+
require 'time'
|
14
15
|
|
15
16
|
module PulpDebClient
|
16
|
-
#
|
17
|
-
class
|
18
|
-
|
19
|
-
attr_accessor :repository
|
17
|
+
# Serializer to add/remove object roles to/from users/groups. This is used in conjunction with ``pulpcore.app.viewsets.base.RolesMixin`` and requires the underlying object to be passed as ``content_object`` in the context.
|
18
|
+
class NestedRoleResponse
|
19
|
+
attr_accessor :users
|
20
20
|
|
21
|
-
|
22
|
-
attr_accessor :artifact
|
21
|
+
attr_accessor :groups
|
23
22
|
|
24
|
-
|
25
|
-
attr_accessor :relative_path
|
26
|
-
|
27
|
-
# An uploaded file that may be turned into the content unit.
|
28
|
-
attr_accessor :file
|
29
|
-
|
30
|
-
# An uncommitted upload that may be turned into the content unit.
|
31
|
-
attr_accessor :upload
|
32
|
-
|
33
|
-
# A url that Pulp can download and turn into the content unit.
|
34
|
-
attr_accessor :file_url
|
23
|
+
attr_accessor :role
|
35
24
|
|
36
25
|
# Attribute mapping from ruby-style variable name to JSON key.
|
37
26
|
def self.attribute_map
|
38
27
|
{
|
39
|
-
:'
|
40
|
-
:'
|
41
|
-
:'
|
42
|
-
:'file' => :'file',
|
43
|
-
:'upload' => :'upload',
|
44
|
-
:'file_url' => :'file_url'
|
28
|
+
:'users' => :'users',
|
29
|
+
:'groups' => :'groups',
|
30
|
+
:'role' => :'role'
|
45
31
|
}
|
46
32
|
end
|
47
33
|
|
34
|
+
# Returns all the JSON keys this model knows about
|
35
|
+
def self.acceptable_attributes
|
36
|
+
attribute_map.values
|
37
|
+
end
|
38
|
+
|
48
39
|
# Attribute type mapping.
|
49
40
|
def self.openapi_types
|
50
41
|
{
|
51
|
-
:'
|
52
|
-
:'
|
53
|
-
:'
|
54
|
-
:'file' => :'File',
|
55
|
-
:'upload' => :'String',
|
56
|
-
:'file_url' => :'String'
|
42
|
+
:'users' => :'Array<String>',
|
43
|
+
:'groups' => :'Array<String>',
|
44
|
+
:'role' => :'String'
|
57
45
|
}
|
58
46
|
end
|
59
47
|
|
@@ -67,56 +55,43 @@ module PulpDebClient
|
|
67
55
|
# @param [Hash] attributes Model attributes in the form of hash
|
68
56
|
def initialize(attributes = {})
|
69
57
|
if (!attributes.is_a?(Hash))
|
70
|
-
fail ArgumentError, "The input argument (attributes) must be a hash in `PulpDebClient::
|
58
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `PulpDebClient::NestedRoleResponse` initialize method"
|
71
59
|
end
|
72
60
|
|
73
61
|
# check to see if the attribute exists and convert string to symbol for hash key
|
74
62
|
attributes = attributes.each_with_object({}) { |(k, v), h|
|
75
63
|
if (!self.class.attribute_map.key?(k.to_sym))
|
76
|
-
fail ArgumentError, "`#{k}` is not a valid attribute in `PulpDebClient::
|
64
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `PulpDebClient::NestedRoleResponse`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
77
65
|
end
|
78
66
|
h[k.to_sym] = v
|
79
67
|
}
|
80
68
|
|
81
|
-
if attributes.key?(:'
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
if attributes.key?(:'artifact')
|
86
|
-
self.artifact = attributes[:'artifact']
|
87
|
-
end
|
88
|
-
|
89
|
-
if attributes.key?(:'relative_path')
|
90
|
-
self.relative_path = attributes[:'relative_path']
|
91
|
-
end
|
92
|
-
|
93
|
-
if attributes.key?(:'file')
|
94
|
-
self.file = attributes[:'file']
|
69
|
+
if attributes.key?(:'users')
|
70
|
+
if (value = attributes[:'users']).is_a?(Array)
|
71
|
+
self.users = value
|
72
|
+
end
|
95
73
|
end
|
96
74
|
|
97
|
-
if attributes.key?(:'
|
98
|
-
|
75
|
+
if attributes.key?(:'groups')
|
76
|
+
if (value = attributes[:'groups']).is_a?(Array)
|
77
|
+
self.groups = value
|
78
|
+
end
|
99
79
|
end
|
100
80
|
|
101
|
-
if attributes.key?(:'
|
102
|
-
self.
|
81
|
+
if attributes.key?(:'role')
|
82
|
+
self.role = attributes[:'role']
|
83
|
+
else
|
84
|
+
self.role = nil
|
103
85
|
end
|
104
86
|
end
|
105
87
|
|
106
88
|
# Show invalid properties with the reasons. Usually used together with valid?
|
107
89
|
# @return Array for valid properties with the reasons
|
108
90
|
def list_invalid_properties
|
91
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
109
92
|
invalid_properties = Array.new
|
110
|
-
if @
|
111
|
-
invalid_properties.push('invalid value for "
|
112
|
-
end
|
113
|
-
|
114
|
-
if @relative_path.to_s.length < 1
|
115
|
-
invalid_properties.push('invalid value for "relative_path", the character length must be great than or equal to 1.')
|
116
|
-
end
|
117
|
-
|
118
|
-
if !@file_url.nil? && @file_url.to_s.length < 1
|
119
|
-
invalid_properties.push('invalid value for "file_url", the character length must be great than or equal to 1.')
|
93
|
+
if @role.nil?
|
94
|
+
invalid_properties.push('invalid value for "role", role cannot be nil.')
|
120
95
|
end
|
121
96
|
|
122
97
|
invalid_properties
|
@@ -125,47 +100,19 @@ module PulpDebClient
|
|
125
100
|
# Check to see if the all the properties in the model are valid
|
126
101
|
# @return true if the model is valid
|
127
102
|
def valid?
|
128
|
-
|
129
|
-
return false if @
|
130
|
-
return false if !@file_url.nil? && @file_url.to_s.length < 1
|
103
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
104
|
+
return false if @role.nil?
|
131
105
|
true
|
132
106
|
end
|
133
107
|
|
134
|
-
# Custom attribute writer method with validation
|
135
|
-
# @param [Object] relative_path Value to be assigned
|
136
|
-
def relative_path=(relative_path)
|
137
|
-
if relative_path.nil?
|
138
|
-
fail ArgumentError, 'relative_path cannot be nil'
|
139
|
-
end
|
140
|
-
|
141
|
-
if relative_path.to_s.length < 1
|
142
|
-
fail ArgumentError, 'invalid value for "relative_path", the character length must be great than or equal to 1.'
|
143
|
-
end
|
144
|
-
|
145
|
-
@relative_path = relative_path
|
146
|
-
end
|
147
|
-
|
148
|
-
# Custom attribute writer method with validation
|
149
|
-
# @param [Object] file_url Value to be assigned
|
150
|
-
def file_url=(file_url)
|
151
|
-
if !file_url.nil? && file_url.to_s.length < 1
|
152
|
-
fail ArgumentError, 'invalid value for "file_url", the character length must be great than or equal to 1.'
|
153
|
-
end
|
154
|
-
|
155
|
-
@file_url = file_url
|
156
|
-
end
|
157
|
-
|
158
108
|
# Checks equality by comparing each attribute.
|
159
109
|
# @param [Object] Object to be compared
|
160
110
|
def ==(o)
|
161
111
|
return true if self.equal?(o)
|
162
112
|
self.class == o.class &&
|
163
|
-
|
164
|
-
|
165
|
-
|
166
|
-
file == o.file &&
|
167
|
-
upload == o.upload &&
|
168
|
-
file_url == o.file_url
|
113
|
+
users == o.users &&
|
114
|
+
groups == o.groups &&
|
115
|
+
role == o.role
|
169
116
|
end
|
170
117
|
|
171
118
|
# @see the `==` method
|
@@ -177,44 +124,40 @@ module PulpDebClient
|
|
177
124
|
# Calculates hash code according to all attributes.
|
178
125
|
# @return [Integer] Hash code
|
179
126
|
def hash
|
180
|
-
[
|
127
|
+
[users, groups, role].hash
|
181
128
|
end
|
182
129
|
|
183
130
|
# Builds the object from hash
|
184
131
|
# @param [Hash] attributes Model attributes in the form of hash
|
185
132
|
# @return [Object] Returns the model itself
|
186
133
|
def self.build_from_hash(attributes)
|
187
|
-
new.build_from_hash(attributes)
|
188
|
-
end
|
189
|
-
|
190
|
-
# Builds the object from hash
|
191
|
-
# @param [Hash] attributes Model attributes in the form of hash
|
192
|
-
# @return [Object] Returns the model itself
|
193
|
-
def build_from_hash(attributes)
|
194
134
|
return nil unless attributes.is_a?(Hash)
|
195
|
-
|
196
|
-
|
135
|
+
attributes = attributes.transform_keys(&:to_sym)
|
136
|
+
transformed_hash = {}
|
137
|
+
openapi_types.each_pair do |key, type|
|
138
|
+
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
139
|
+
transformed_hash["#{key}"] = nil
|
140
|
+
elsif type =~ /\AArray<(.*)>/i
|
197
141
|
# check to ensure the input is an array given that the attribute
|
198
142
|
# is documented as an array but the input is not
|
199
|
-
if attributes[
|
200
|
-
|
143
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
144
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
201
145
|
end
|
202
|
-
elsif !attributes[
|
203
|
-
|
204
|
-
end
|
146
|
+
elsif !attributes[attribute_map[key]].nil?
|
147
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
148
|
+
end
|
205
149
|
end
|
206
|
-
|
207
|
-
self
|
150
|
+
new(transformed_hash)
|
208
151
|
end
|
209
152
|
|
210
153
|
# Deserializes the data based on type
|
211
154
|
# @param string type Data type
|
212
155
|
# @param string value Value to be deserialized
|
213
156
|
# @return [Object] Deserialized data
|
214
|
-
def _deserialize(type, value)
|
157
|
+
def self._deserialize(type, value)
|
215
158
|
case type.to_sym
|
216
|
-
when :
|
217
|
-
|
159
|
+
when :Time
|
160
|
+
Time.parse(value)
|
218
161
|
when :Date
|
219
162
|
Date.parse(value)
|
220
163
|
when :String
|
@@ -244,7 +187,9 @@ module PulpDebClient
|
|
244
187
|
end
|
245
188
|
end
|
246
189
|
else # model
|
247
|
-
|
190
|
+
# models (e.g. Pet) or oneOf
|
191
|
+
klass = PulpDebClient.const_get(type)
|
192
|
+
klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
248
193
|
end
|
249
194
|
end
|
250
195
|
|
@@ -270,7 +215,7 @@ module PulpDebClient
|
|
270
215
|
is_nullable = self.class.openapi_nullable.include?(attr)
|
271
216
|
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
272
217
|
end
|
273
|
-
|
218
|
+
|
274
219
|
hash[param] = _to_hash(value)
|
275
220
|
end
|
276
221
|
hash
|
@@ -293,5 +238,7 @@ module PulpDebClient
|
|
293
238
|
value
|
294
239
|
end
|
295
240
|
end
|
241
|
+
|
296
242
|
end
|
243
|
+
|
297
244
|
end
|