msgraph-sdk 1.14.0__py3-none-any.whl → 1.15.0__py3-none-any.whl
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.
- msgraph/_version.py +1 -1
- msgraph/generated/app_catalogs/teams_apps/teams_apps_request_builder.py +3 -3
- msgraph/generated/chats/item/members/item/conversation_member_item_request_builder.py +4 -4
- msgraph/generated/communications/calls/item/participants/invite/invite_request_builder.py +3 -3
- msgraph/generated/device_app_management/device_app_management_request_builder.py +1 -1
- msgraph/generated/device_app_management/managed_app_policies/item/managed_app_policy_item_request_builder.py +4 -4
- msgraph/generated/device_app_management/managed_app_policies/item/target_apps/target_apps_request_builder.py +1 -1
- msgraph/generated/device_app_management/managed_app_policies/managed_app_policies_request_builder.py +4 -4
- msgraph/generated/device_app_management/managed_app_registrations/item/applied_policies/item/target_apps/target_apps_request_builder.py +1 -1
- msgraph/generated/device_app_management/managed_app_registrations/item/intended_policies/item/target_apps/target_apps_request_builder.py +1 -1
- msgraph/generated/device_app_management/managed_app_registrations/item/managed_app_registration_item_request_builder.py +4 -4
- msgraph/generated/device_app_management/managed_e_books/item/assignments/assignments_request_builder.py +4 -4
- msgraph/generated/device_app_management/managed_e_books/item/assignments/item/managed_e_book_assignment_item_request_builder.py +10 -10
- msgraph/generated/device_app_management/managed_e_books/managed_e_books_request_builder.py +4 -4
- msgraph/generated/device_app_management/mobile_app_configurations/item/managed_device_mobile_app_configuration_item_request_builder.py +4 -4
- msgraph/generated/device_app_management/mobile_app_configurations/mobile_app_configurations_request_builder.py +4 -4
- msgraph/generated/device_app_management/mobile_apps/item/mobile_app_item_request_builder.py +10 -10
- msgraph/generated/device_app_management/mobile_apps/mobile_apps_request_builder.py +7 -7
- msgraph/generated/device_management/device_compliance_policies/device_compliance_policies_request_builder.py +3 -3
- msgraph/generated/device_management/device_compliance_policies/item/device_compliance_policy_item_request_builder.py +10 -10
- msgraph/generated/device_management/device_configurations/device_configurations_request_builder.py +3 -3
- msgraph/generated/device_management/device_configurations/item/device_configuration_item_request_builder.py +7 -7
- msgraph/generated/device_management/device_enrollment_configurations/device_enrollment_configurations_request_builder.py +3 -3
- msgraph/generated/device_management/device_enrollment_configurations/item/device_enrollment_configuration_item_request_builder.py +6 -6
- msgraph/generated/device_management/device_management_request_builder.py +2 -2
- msgraph/generated/device_management/role_definitions/item/role_definition_item_request_builder.py +3 -3
- msgraph/generated/drives/item/items/item/discard_checkout/discard_checkout_request_builder.py +78 -0
- msgraph/generated/drives/item/items/item/drive_item_item_request_builder.py +10 -0
- msgraph/generated/drives/item/items/item/retention_label/retention_label_request_builder.py +3 -3
- msgraph/generated/drives/item/items/item/workbook/tables/add/add_request_builder.py +3 -3
- msgraph/generated/drives/item/items/item/workbook/worksheets/item/tables/add/add_request_builder.py +3 -3
- msgraph/generated/external/connections/item/items/item/external_item_item_request_builder.py +3 -3
- msgraph/generated/groups/groups_request_builder.py +3 -3
- msgraph/generated/groups/item/assign_license/assign_license_request_builder.py +2 -2
- msgraph/generated/groups/item/conversations/conversations_request_builder.py +3 -3
- msgraph/generated/groups/item/conversations/item/conversation_item_request_builder.py +1 -1
- msgraph/generated/groups/item/group_item_request_builder.py +2 -2
- msgraph/generated/groups/item/renew/renew_request_builder.py +2 -2
- msgraph/generated/groups/item/threads/item/conversation_thread_item_request_builder.py +5 -5
- msgraph/generated/groups/item/threads/item/posts/posts_request_builder.py +4 -4
- msgraph/generated/groups_with_unique_name/groups_with_unique_name_request_builder.py +2 -2
- msgraph/generated/identity/conditional_access/named_locations/item/named_location_item_request_builder.py +10 -10
- msgraph/generated/identity_governance/entitlement_management/access_packages/item/access_package_item_request_builder.py +4 -4
- msgraph/generated/identity_governance/entitlement_management/catalogs/item/custom_workflow_extensions/item/custom_callout_extension_item_request_builder.py +6 -6
- msgraph/generated/identity_governance/terms_of_use/agreements/item/agreement_item_request_builder.py +4 -4
- msgraph/generated/information_protection/bitlocker/recovery_keys/recovery_keys_request_builder.py +3 -3
- msgraph/generated/kiota-dom-export.txt +989 -0
- msgraph/generated/kiota-lock.json +2 -2
- msgraph/generated/models/administrative_unit.py +1 -1
- msgraph/generated/models/app_role_assignment.py +2 -2
- msgraph/generated/models/application.py +1 -1
- msgraph/generated/models/base_item.py +16 -0
- msgraph/generated/models/conditional_access_client_applications.py +1 -1
- msgraph/generated/models/conditional_access_condition_set.py +2 -2
- msgraph/generated/models/device.py +1 -1
- msgraph/generated/models/eligibility_filtering_enabled_entities.py +9 -0
- msgraph/generated/models/entity.py +16 -0
- msgraph/generated/models/file_storage.py +4 -0
- msgraph/generated/models/file_storage_container.py +16 -0
- msgraph/generated/models/file_storage_container_settings.py +8 -0
- msgraph/generated/models/internal_domain_federation.py +4 -0
- msgraph/generated/models/open_shift.py +7 -3
- msgraph/generated/models/org_contact.py +1 -1
- msgraph/generated/models/recycle_bin.py +70 -0
- msgraph/generated/models/recycle_bin_item.py +67 -0
- msgraph/generated/models/recycle_bin_item_collection_response.py +60 -0
- msgraph/generated/models/recycle_bin_settings.py +53 -0
- msgraph/generated/models/security/data_set.py +4 -0
- msgraph/generated/models/service_principal.py +1 -1
- msgraph/generated/models/shift.py +4 -0
- msgraph/generated/models/shift_activity.py +2 -2
- msgraph/generated/models/site_lock_state.py +9 -0
- msgraph/generated/models/time_off.py +5 -1
- msgraph/generated/models/user.py +1 -1
- msgraph/generated/models/workforce_integration.py +9 -1
- msgraph/generated/models/workforce_integration_supported_entities.py +3 -0
- msgraph/generated/models/x509_certificate_authentication_method_configuration.py +8 -0
- msgraph/generated/models/x509_certificate_c_r_l_validation_configuration.py +66 -0
- msgraph/generated/models/x509_certificate_c_r_l_validation_configuration_state.py +7 -0
- msgraph/generated/organization/item/branding/localizations/item/banner_logo/banner_logo_request_builder.py +3 -3
- msgraph/generated/organization/item/organization_item_request_builder.py +4 -4
- msgraph/generated/security/attack_simulation/payloads/item/payload_item_request_builder.py +4 -3
- msgraph/generated/storage/file_storage/containers/item/file_storage_container_item_request_builder.py +40 -0
- msgraph/generated/storage/file_storage/containers/item/lock/lock_post_request_body.py +58 -0
- msgraph/generated/storage/file_storage/containers/item/lock/lock_request_builder.py +85 -0
- msgraph/generated/storage/file_storage/containers/item/recycle_bin/created_by_user/created_by_user_request_builder.py +126 -0
- msgraph/generated/storage/file_storage/containers/item/recycle_bin/created_by_user/mailbox_settings/mailbox_settings_request_builder.py +151 -0
- msgraph/generated/storage/file_storage/containers/item/recycle_bin/created_by_user/service_provisioning_errors/count/count_request_builder.py +103 -0
- msgraph/generated/storage/file_storage/containers/item/recycle_bin/created_by_user/service_provisioning_errors/service_provisioning_errors_request_builder.py +146 -0
- msgraph/generated/storage/file_storage/containers/item/recycle_bin/items/count/count_request_builder.py +103 -0
- msgraph/generated/storage/file_storage/containers/item/recycle_bin/items/item/created_by_user/created_by_user_request_builder.py +126 -0
- msgraph/generated/storage/file_storage/containers/item/recycle_bin/items/item/created_by_user/mailbox_settings/mailbox_settings_request_builder.py +151 -0
- msgraph/generated/storage/file_storage/containers/item/recycle_bin/items/item/created_by_user/service_provisioning_errors/count/count_request_builder.py +103 -0
- msgraph/generated/storage/file_storage/containers/item/recycle_bin/items/item/created_by_user/service_provisioning_errors/service_provisioning_errors_request_builder.py +146 -0
- msgraph/generated/storage/file_storage/containers/item/recycle_bin/items/item/last_modified_by_user/last_modified_by_user_request_builder.py +126 -0
- msgraph/generated/storage/file_storage/containers/item/recycle_bin/items/item/last_modified_by_user/mailbox_settings/mailbox_settings_request_builder.py +151 -0
- msgraph/generated/storage/file_storage/containers/item/recycle_bin/items/item/last_modified_by_user/service_provisioning_errors/count/count_request_builder.py +103 -0
- msgraph/generated/storage/file_storage/containers/item/recycle_bin/items/item/last_modified_by_user/service_provisioning_errors/service_provisioning_errors_request_builder.py +146 -0
- msgraph/generated/storage/file_storage/containers/item/recycle_bin/items/item/recycle_bin_item_item_request_builder.py +207 -0
- msgraph/generated/storage/file_storage/containers/item/recycle_bin/items/items_request_builder.py +207 -0
- msgraph/generated/storage/file_storage/containers/item/recycle_bin/last_modified_by_user/last_modified_by_user_request_builder.py +126 -0
- msgraph/generated/storage/file_storage/containers/item/recycle_bin/last_modified_by_user/mailbox_settings/mailbox_settings_request_builder.py +151 -0
- msgraph/generated/storage/file_storage/containers/item/recycle_bin/last_modified_by_user/service_provisioning_errors/count/count_request_builder.py +103 -0
- msgraph/generated/storage/file_storage/containers/item/recycle_bin/last_modified_by_user/service_provisioning_errors/service_provisioning_errors_request_builder.py +146 -0
- msgraph/generated/storage/file_storage/containers/item/recycle_bin/recycle_bin_request_builder.py +217 -0
- msgraph/generated/storage/file_storage/containers/item/restore/restore_request_builder.py +80 -0
- msgraph/generated/storage/file_storage/containers/item/unlock/unlock_request_builder.py +77 -0
- msgraph/generated/storage/file_storage/deleted_containers/count/count_request_builder.py +103 -0
- msgraph/generated/storage/file_storage/deleted_containers/deleted_containers_request_builder.py +207 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/activate/activate_request_builder.py +77 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/drive/drive_request_builder.py +106 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/file_storage_container_item_request_builder.py +267 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/lock/lock_post_request_body.py +58 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/lock/lock_request_builder.py +85 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/permanent_delete/permanent_delete_request_builder.py +77 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/permissions/count/count_request_builder.py +103 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/permissions/item/grant/grant_post_request_body.py +62 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/permissions/item/grant/grant_post_response.py +60 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/permissions/item/grant/grant_request_builder.py +89 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/permissions/item/permission_item_request_builder.py +197 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/permissions/permissions_request_builder.py +207 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/recycle_bin/created_by_user/created_by_user_request_builder.py +126 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/recycle_bin/created_by_user/mailbox_settings/mailbox_settings_request_builder.py +151 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/recycle_bin/created_by_user/service_provisioning_errors/count/count_request_builder.py +103 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/recycle_bin/created_by_user/service_provisioning_errors/service_provisioning_errors_request_builder.py +146 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/recycle_bin/items/count/count_request_builder.py +103 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/recycle_bin/items/item/created_by_user/created_by_user_request_builder.py +126 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/recycle_bin/items/item/created_by_user/mailbox_settings/mailbox_settings_request_builder.py +151 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/recycle_bin/items/item/created_by_user/service_provisioning_errors/count/count_request_builder.py +103 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/recycle_bin/items/item/created_by_user/service_provisioning_errors/service_provisioning_errors_request_builder.py +146 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/recycle_bin/items/item/last_modified_by_user/last_modified_by_user_request_builder.py +126 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/recycle_bin/items/item/last_modified_by_user/mailbox_settings/mailbox_settings_request_builder.py +151 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/recycle_bin/items/item/last_modified_by_user/service_provisioning_errors/count/count_request_builder.py +103 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/recycle_bin/items/item/last_modified_by_user/service_provisioning_errors/service_provisioning_errors_request_builder.py +146 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/recycle_bin/items/item/recycle_bin_item_item_request_builder.py +207 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/recycle_bin/items/items_request_builder.py +207 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/recycle_bin/last_modified_by_user/last_modified_by_user_request_builder.py +126 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/recycle_bin/last_modified_by_user/mailbox_settings/mailbox_settings_request_builder.py +151 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/recycle_bin/last_modified_by_user/service_provisioning_errors/count/count_request_builder.py +103 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/recycle_bin/last_modified_by_user/service_provisioning_errors/service_provisioning_errors_request_builder.py +146 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/recycle_bin/recycle_bin_request_builder.py +217 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/restore/restore_request_builder.py +80 -0
- msgraph/generated/storage/file_storage/deleted_containers/item/unlock/unlock_request_builder.py +77 -0
- msgraph/generated/storage/file_storage/file_storage_request_builder.py +10 -0
- msgraph/generated/teams/item/channels/item/members/item/conversation_member_item_request_builder.py +3 -3
- msgraph/generated/teams/item/channels/item/members/members_request_builder.py +3 -3
- msgraph/generated/teams/item/channels/item/messages/item/replies/replies_request_builder.py +3 -3
- msgraph/generated/users/item/presence/presence_request_builder.py +4 -4
- msgraph/generated/users/item/user_item_request_builder.py +2 -2
- msgraph/generated/users/users_request_builder.py +5 -5
- msgraph/generated/users_with_user_principal_name/users_with_user_principal_name_request_builder.py +2 -2
- {msgraph_sdk-1.14.0.dist-info → msgraph_sdk-1.15.0.dist-info}/METADATA +1 -1
- {msgraph_sdk-1.14.0.dist-info → msgraph_sdk-1.15.0.dist-info}/RECORD +155 -86
- {msgraph_sdk-1.14.0.dist-info → msgraph_sdk-1.15.0.dist-info}/LICENSE +0 -0
- {msgraph_sdk-1.14.0.dist-info → msgraph_sdk-1.15.0.dist-info}/WHEEL +0 -0
@@ -0,0 +1,267 @@
|
|
1
|
+
from __future__ import annotations
|
2
|
+
from dataclasses import dataclass, field
|
3
|
+
from kiota_abstractions.base_request_builder import BaseRequestBuilder
|
4
|
+
from kiota_abstractions.base_request_configuration import RequestConfiguration
|
5
|
+
from kiota_abstractions.default_query_parameters import QueryParameters
|
6
|
+
from kiota_abstractions.get_path_parameters import get_path_parameters
|
7
|
+
from kiota_abstractions.method import Method
|
8
|
+
from kiota_abstractions.request_adapter import RequestAdapter
|
9
|
+
from kiota_abstractions.request_information import RequestInformation
|
10
|
+
from kiota_abstractions.request_option import RequestOption
|
11
|
+
from kiota_abstractions.serialization import Parsable, ParsableFactory
|
12
|
+
from typing import Any, Callable, Dict, List, Optional, TYPE_CHECKING, Union
|
13
|
+
from warnings import warn
|
14
|
+
|
15
|
+
if TYPE_CHECKING:
|
16
|
+
from .....models.file_storage_container import FileStorageContainer
|
17
|
+
from .....models.o_data_errors.o_data_error import ODataError
|
18
|
+
from .activate.activate_request_builder import ActivateRequestBuilder
|
19
|
+
from .drive.drive_request_builder import DriveRequestBuilder
|
20
|
+
from .lock.lock_request_builder import LockRequestBuilder
|
21
|
+
from .permanent_delete.permanent_delete_request_builder import PermanentDeleteRequestBuilder
|
22
|
+
from .permissions.permissions_request_builder import PermissionsRequestBuilder
|
23
|
+
from .recycle_bin.recycle_bin_request_builder import RecycleBinRequestBuilder
|
24
|
+
from .restore.restore_request_builder import RestoreRequestBuilder
|
25
|
+
from .unlock.unlock_request_builder import UnlockRequestBuilder
|
26
|
+
|
27
|
+
class FileStorageContainerItemRequestBuilder(BaseRequestBuilder):
|
28
|
+
"""
|
29
|
+
Provides operations to manage the deletedContainers property of the microsoft.graph.fileStorage entity.
|
30
|
+
"""
|
31
|
+
def __init__(self,request_adapter: RequestAdapter, path_parameters: Union[str, Dict[str, Any]]) -> None:
|
32
|
+
"""
|
33
|
+
Instantiates a new FileStorageContainerItemRequestBuilder and sets the default values.
|
34
|
+
param path_parameters: The raw url or the url-template parameters for the request.
|
35
|
+
param request_adapter: The request adapter to use to execute the requests.
|
36
|
+
Returns: None
|
37
|
+
"""
|
38
|
+
super().__init__(request_adapter, "{+baseurl}/storage/fileStorage/deletedContainers/{fileStorageContainer%2Did}{?%24expand,%24select}", path_parameters)
|
39
|
+
|
40
|
+
async def delete(self,request_configuration: Optional[RequestConfiguration[QueryParameters]] = None) -> None:
|
41
|
+
"""
|
42
|
+
Delete navigation property deletedContainers for storage
|
43
|
+
param request_configuration: Configuration for the request such as headers, query parameters, and middleware options.
|
44
|
+
Returns: None
|
45
|
+
"""
|
46
|
+
request_info = self.to_delete_request_information(
|
47
|
+
request_configuration
|
48
|
+
)
|
49
|
+
from .....models.o_data_errors.o_data_error import ODataError
|
50
|
+
|
51
|
+
error_mapping: Dict[str, type[ParsableFactory]] = {
|
52
|
+
"XXX": ODataError,
|
53
|
+
}
|
54
|
+
if not self.request_adapter:
|
55
|
+
raise Exception("Http core is null")
|
56
|
+
return await self.request_adapter.send_no_response_content_async(request_info, error_mapping)
|
57
|
+
|
58
|
+
async def get(self,request_configuration: Optional[RequestConfiguration[FileStorageContainerItemRequestBuilderGetQueryParameters]] = None) -> Optional[FileStorageContainer]:
|
59
|
+
"""
|
60
|
+
Get deletedContainers from storage
|
61
|
+
param request_configuration: Configuration for the request such as headers, query parameters, and middleware options.
|
62
|
+
Returns: Optional[FileStorageContainer]
|
63
|
+
"""
|
64
|
+
request_info = self.to_get_request_information(
|
65
|
+
request_configuration
|
66
|
+
)
|
67
|
+
from .....models.o_data_errors.o_data_error import ODataError
|
68
|
+
|
69
|
+
error_mapping: Dict[str, type[ParsableFactory]] = {
|
70
|
+
"XXX": ODataError,
|
71
|
+
}
|
72
|
+
if not self.request_adapter:
|
73
|
+
raise Exception("Http core is null")
|
74
|
+
from .....models.file_storage_container import FileStorageContainer
|
75
|
+
|
76
|
+
return await self.request_adapter.send_async(request_info, FileStorageContainer, error_mapping)
|
77
|
+
|
78
|
+
async def patch(self,body: FileStorageContainer, request_configuration: Optional[RequestConfiguration[QueryParameters]] = None) -> Optional[FileStorageContainer]:
|
79
|
+
"""
|
80
|
+
Update the navigation property deletedContainers in storage
|
81
|
+
param body: The request body
|
82
|
+
param request_configuration: Configuration for the request such as headers, query parameters, and middleware options.
|
83
|
+
Returns: Optional[FileStorageContainer]
|
84
|
+
"""
|
85
|
+
if body is None:
|
86
|
+
raise TypeError("body cannot be null.")
|
87
|
+
request_info = self.to_patch_request_information(
|
88
|
+
body, request_configuration
|
89
|
+
)
|
90
|
+
from .....models.o_data_errors.o_data_error import ODataError
|
91
|
+
|
92
|
+
error_mapping: Dict[str, type[ParsableFactory]] = {
|
93
|
+
"XXX": ODataError,
|
94
|
+
}
|
95
|
+
if not self.request_adapter:
|
96
|
+
raise Exception("Http core is null")
|
97
|
+
from .....models.file_storage_container import FileStorageContainer
|
98
|
+
|
99
|
+
return await self.request_adapter.send_async(request_info, FileStorageContainer, error_mapping)
|
100
|
+
|
101
|
+
def to_delete_request_information(self,request_configuration: Optional[RequestConfiguration[QueryParameters]] = None) -> RequestInformation:
|
102
|
+
"""
|
103
|
+
Delete navigation property deletedContainers for storage
|
104
|
+
param request_configuration: Configuration for the request such as headers, query parameters, and middleware options.
|
105
|
+
Returns: RequestInformation
|
106
|
+
"""
|
107
|
+
request_info = RequestInformation(Method.DELETE, self.url_template, self.path_parameters)
|
108
|
+
request_info.configure(request_configuration)
|
109
|
+
request_info.headers.try_add("Accept", "application/json")
|
110
|
+
return request_info
|
111
|
+
|
112
|
+
def to_get_request_information(self,request_configuration: Optional[RequestConfiguration[FileStorageContainerItemRequestBuilderGetQueryParameters]] = None) -> RequestInformation:
|
113
|
+
"""
|
114
|
+
Get deletedContainers from storage
|
115
|
+
param request_configuration: Configuration for the request such as headers, query parameters, and middleware options.
|
116
|
+
Returns: RequestInformation
|
117
|
+
"""
|
118
|
+
request_info = RequestInformation(Method.GET, self.url_template, self.path_parameters)
|
119
|
+
request_info.configure(request_configuration)
|
120
|
+
request_info.headers.try_add("Accept", "application/json")
|
121
|
+
return request_info
|
122
|
+
|
123
|
+
def to_patch_request_information(self,body: FileStorageContainer, request_configuration: Optional[RequestConfiguration[QueryParameters]] = None) -> RequestInformation:
|
124
|
+
"""
|
125
|
+
Update the navigation property deletedContainers in storage
|
126
|
+
param body: The request body
|
127
|
+
param request_configuration: Configuration for the request such as headers, query parameters, and middleware options.
|
128
|
+
Returns: RequestInformation
|
129
|
+
"""
|
130
|
+
if body is None:
|
131
|
+
raise TypeError("body cannot be null.")
|
132
|
+
request_info = RequestInformation(Method.PATCH, self.url_template, self.path_parameters)
|
133
|
+
request_info.configure(request_configuration)
|
134
|
+
request_info.headers.try_add("Accept", "application/json")
|
135
|
+
request_info.set_content_from_parsable(self.request_adapter, "application/json", body)
|
136
|
+
return request_info
|
137
|
+
|
138
|
+
def with_url(self,raw_url: str) -> FileStorageContainerItemRequestBuilder:
|
139
|
+
"""
|
140
|
+
Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored.
|
141
|
+
param raw_url: The raw URL to use for the request builder.
|
142
|
+
Returns: FileStorageContainerItemRequestBuilder
|
143
|
+
"""
|
144
|
+
if raw_url is None:
|
145
|
+
raise TypeError("raw_url cannot be null.")
|
146
|
+
return FileStorageContainerItemRequestBuilder(self.request_adapter, raw_url)
|
147
|
+
|
148
|
+
@property
|
149
|
+
def activate(self) -> ActivateRequestBuilder:
|
150
|
+
"""
|
151
|
+
Provides operations to call the activate method.
|
152
|
+
"""
|
153
|
+
from .activate.activate_request_builder import ActivateRequestBuilder
|
154
|
+
|
155
|
+
return ActivateRequestBuilder(self.request_adapter, self.path_parameters)
|
156
|
+
|
157
|
+
@property
|
158
|
+
def drive(self) -> DriveRequestBuilder:
|
159
|
+
"""
|
160
|
+
Provides operations to manage the drive property of the microsoft.graph.fileStorageContainer entity.
|
161
|
+
"""
|
162
|
+
from .drive.drive_request_builder import DriveRequestBuilder
|
163
|
+
|
164
|
+
return DriveRequestBuilder(self.request_adapter, self.path_parameters)
|
165
|
+
|
166
|
+
@property
|
167
|
+
def lock(self) -> LockRequestBuilder:
|
168
|
+
"""
|
169
|
+
Provides operations to call the lock method.
|
170
|
+
"""
|
171
|
+
from .lock.lock_request_builder import LockRequestBuilder
|
172
|
+
|
173
|
+
return LockRequestBuilder(self.request_adapter, self.path_parameters)
|
174
|
+
|
175
|
+
@property
|
176
|
+
def permanent_delete(self) -> PermanentDeleteRequestBuilder:
|
177
|
+
"""
|
178
|
+
Provides operations to call the permanentDelete method.
|
179
|
+
"""
|
180
|
+
from .permanent_delete.permanent_delete_request_builder import PermanentDeleteRequestBuilder
|
181
|
+
|
182
|
+
return PermanentDeleteRequestBuilder(self.request_adapter, self.path_parameters)
|
183
|
+
|
184
|
+
@property
|
185
|
+
def permissions(self) -> PermissionsRequestBuilder:
|
186
|
+
"""
|
187
|
+
Provides operations to manage the permissions property of the microsoft.graph.fileStorageContainer entity.
|
188
|
+
"""
|
189
|
+
from .permissions.permissions_request_builder import PermissionsRequestBuilder
|
190
|
+
|
191
|
+
return PermissionsRequestBuilder(self.request_adapter, self.path_parameters)
|
192
|
+
|
193
|
+
@property
|
194
|
+
def recycle_bin(self) -> RecycleBinRequestBuilder:
|
195
|
+
"""
|
196
|
+
Provides operations to manage the recycleBin property of the microsoft.graph.fileStorageContainer entity.
|
197
|
+
"""
|
198
|
+
from .recycle_bin.recycle_bin_request_builder import RecycleBinRequestBuilder
|
199
|
+
|
200
|
+
return RecycleBinRequestBuilder(self.request_adapter, self.path_parameters)
|
201
|
+
|
202
|
+
@property
|
203
|
+
def restore(self) -> RestoreRequestBuilder:
|
204
|
+
"""
|
205
|
+
Provides operations to call the restore method.
|
206
|
+
"""
|
207
|
+
from .restore.restore_request_builder import RestoreRequestBuilder
|
208
|
+
|
209
|
+
return RestoreRequestBuilder(self.request_adapter, self.path_parameters)
|
210
|
+
|
211
|
+
@property
|
212
|
+
def unlock(self) -> UnlockRequestBuilder:
|
213
|
+
"""
|
214
|
+
Provides operations to call the unlock method.
|
215
|
+
"""
|
216
|
+
from .unlock.unlock_request_builder import UnlockRequestBuilder
|
217
|
+
|
218
|
+
return UnlockRequestBuilder(self.request_adapter, self.path_parameters)
|
219
|
+
|
220
|
+
@dataclass
|
221
|
+
class FileStorageContainerItemRequestBuilderDeleteRequestConfiguration(RequestConfiguration[QueryParameters]):
|
222
|
+
"""
|
223
|
+
Configuration for the request such as headers, query parameters, and middleware options.
|
224
|
+
"""
|
225
|
+
warn("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.", DeprecationWarning)
|
226
|
+
|
227
|
+
@dataclass
|
228
|
+
class FileStorageContainerItemRequestBuilderGetQueryParameters():
|
229
|
+
"""
|
230
|
+
Get deletedContainers from storage
|
231
|
+
"""
|
232
|
+
def get_query_parameter(self,original_name: str) -> str:
|
233
|
+
"""
|
234
|
+
Maps the query parameters names to their encoded names for the URI template parsing.
|
235
|
+
param original_name: The original query parameter name in the class.
|
236
|
+
Returns: str
|
237
|
+
"""
|
238
|
+
if original_name is None:
|
239
|
+
raise TypeError("original_name cannot be null.")
|
240
|
+
if original_name == "expand":
|
241
|
+
return "%24expand"
|
242
|
+
if original_name == "select":
|
243
|
+
return "%24select"
|
244
|
+
return original_name
|
245
|
+
|
246
|
+
# Expand related entities
|
247
|
+
expand: Optional[List[str]] = None
|
248
|
+
|
249
|
+
# Select properties to be returned
|
250
|
+
select: Optional[List[str]] = None
|
251
|
+
|
252
|
+
|
253
|
+
@dataclass
|
254
|
+
class FileStorageContainerItemRequestBuilderGetRequestConfiguration(RequestConfiguration[FileStorageContainerItemRequestBuilderGetQueryParameters]):
|
255
|
+
"""
|
256
|
+
Configuration for the request such as headers, query parameters, and middleware options.
|
257
|
+
"""
|
258
|
+
warn("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.", DeprecationWarning)
|
259
|
+
|
260
|
+
@dataclass
|
261
|
+
class FileStorageContainerItemRequestBuilderPatchRequestConfiguration(RequestConfiguration[QueryParameters]):
|
262
|
+
"""
|
263
|
+
Configuration for the request such as headers, query parameters, and middleware options.
|
264
|
+
"""
|
265
|
+
warn("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.", DeprecationWarning)
|
266
|
+
|
267
|
+
|
@@ -0,0 +1,58 @@
|
|
1
|
+
from __future__ import annotations
|
2
|
+
from dataclasses import dataclass, field
|
3
|
+
from kiota_abstractions.serialization import AdditionalDataHolder, Parsable, ParseNode, SerializationWriter
|
4
|
+
from kiota_abstractions.store import BackedModel, BackingStore, BackingStoreFactorySingleton
|
5
|
+
from typing import Any, Callable, Dict, List, Optional, TYPE_CHECKING, Union
|
6
|
+
|
7
|
+
if TYPE_CHECKING:
|
8
|
+
from ......models.site_lock_state import SiteLockState
|
9
|
+
|
10
|
+
@dataclass
|
11
|
+
class LockPostRequestBody(AdditionalDataHolder, BackedModel, Parsable):
|
12
|
+
# Stores model information.
|
13
|
+
backing_store: BackingStore = field(default_factory=BackingStoreFactorySingleton(backing_store_factory=None).backing_store_factory.create_backing_store, repr=False)
|
14
|
+
|
15
|
+
# Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
16
|
+
additional_data: Dict[str, Any] = field(default_factory=dict)
|
17
|
+
# The lockState property
|
18
|
+
lock_state: Optional[SiteLockState] = None
|
19
|
+
|
20
|
+
@staticmethod
|
21
|
+
def create_from_discriminator_value(parse_node: ParseNode) -> LockPostRequestBody:
|
22
|
+
"""
|
23
|
+
Creates a new instance of the appropriate class based on discriminator value
|
24
|
+
param parse_node: The parse node to use to read the discriminator value and create the object
|
25
|
+
Returns: LockPostRequestBody
|
26
|
+
"""
|
27
|
+
if parse_node is None:
|
28
|
+
raise TypeError("parse_node cannot be null.")
|
29
|
+
return LockPostRequestBody()
|
30
|
+
|
31
|
+
def get_field_deserializers(self,) -> Dict[str, Callable[[ParseNode], None]]:
|
32
|
+
"""
|
33
|
+
The deserialization information for the current model
|
34
|
+
Returns: Dict[str, Callable[[ParseNode], None]]
|
35
|
+
"""
|
36
|
+
from ......models.site_lock_state import SiteLockState
|
37
|
+
|
38
|
+
from ......models.site_lock_state import SiteLockState
|
39
|
+
|
40
|
+
fields: Dict[str, Callable[[Any], None]] = {
|
41
|
+
"lockState": lambda n : setattr(self, 'lock_state', n.get_enum_value(SiteLockState)),
|
42
|
+
}
|
43
|
+
return fields
|
44
|
+
|
45
|
+
def serialize(self,writer: SerializationWriter) -> None:
|
46
|
+
"""
|
47
|
+
Serializes information the current object
|
48
|
+
param writer: Serialization writer to use to serialize this model
|
49
|
+
Returns: None
|
50
|
+
"""
|
51
|
+
if writer is None:
|
52
|
+
raise TypeError("writer cannot be null.")
|
53
|
+
from ......models.site_lock_state import SiteLockState
|
54
|
+
|
55
|
+
writer.write_enum_value("lockState", self.lock_state)
|
56
|
+
writer.write_additional_data_value(self.additional_data)
|
57
|
+
|
58
|
+
|
@@ -0,0 +1,85 @@
|
|
1
|
+
from __future__ import annotations
|
2
|
+
from dataclasses import dataclass, field
|
3
|
+
from kiota_abstractions.base_request_builder import BaseRequestBuilder
|
4
|
+
from kiota_abstractions.base_request_configuration import RequestConfiguration
|
5
|
+
from kiota_abstractions.default_query_parameters import QueryParameters
|
6
|
+
from kiota_abstractions.get_path_parameters import get_path_parameters
|
7
|
+
from kiota_abstractions.method import Method
|
8
|
+
from kiota_abstractions.request_adapter import RequestAdapter
|
9
|
+
from kiota_abstractions.request_information import RequestInformation
|
10
|
+
from kiota_abstractions.request_option import RequestOption
|
11
|
+
from kiota_abstractions.serialization import Parsable, ParsableFactory
|
12
|
+
from typing import Any, Callable, Dict, List, Optional, TYPE_CHECKING, Union
|
13
|
+
from warnings import warn
|
14
|
+
|
15
|
+
if TYPE_CHECKING:
|
16
|
+
from ......models.o_data_errors.o_data_error import ODataError
|
17
|
+
from .lock_post_request_body import LockPostRequestBody
|
18
|
+
|
19
|
+
class LockRequestBuilder(BaseRequestBuilder):
|
20
|
+
"""
|
21
|
+
Provides operations to call the lock method.
|
22
|
+
"""
|
23
|
+
def __init__(self,request_adapter: RequestAdapter, path_parameters: Union[str, Dict[str, Any]]) -> None:
|
24
|
+
"""
|
25
|
+
Instantiates a new LockRequestBuilder and sets the default values.
|
26
|
+
param path_parameters: The raw url or the url-template parameters for the request.
|
27
|
+
param request_adapter: The request adapter to use to execute the requests.
|
28
|
+
Returns: None
|
29
|
+
"""
|
30
|
+
super().__init__(request_adapter, "{+baseurl}/storage/fileStorage/deletedContainers/{fileStorageContainer%2Did}/lock", path_parameters)
|
31
|
+
|
32
|
+
async def post(self,body: LockPostRequestBody, request_configuration: Optional[RequestConfiguration[QueryParameters]] = None) -> None:
|
33
|
+
"""
|
34
|
+
Invoke action lock
|
35
|
+
param body: The request body
|
36
|
+
param request_configuration: Configuration for the request such as headers, query parameters, and middleware options.
|
37
|
+
Returns: None
|
38
|
+
"""
|
39
|
+
if body is None:
|
40
|
+
raise TypeError("body cannot be null.")
|
41
|
+
request_info = self.to_post_request_information(
|
42
|
+
body, request_configuration
|
43
|
+
)
|
44
|
+
from ......models.o_data_errors.o_data_error import ODataError
|
45
|
+
|
46
|
+
error_mapping: Dict[str, type[ParsableFactory]] = {
|
47
|
+
"XXX": ODataError,
|
48
|
+
}
|
49
|
+
if not self.request_adapter:
|
50
|
+
raise Exception("Http core is null")
|
51
|
+
return await self.request_adapter.send_no_response_content_async(request_info, error_mapping)
|
52
|
+
|
53
|
+
def to_post_request_information(self,body: LockPostRequestBody, request_configuration: Optional[RequestConfiguration[QueryParameters]] = None) -> RequestInformation:
|
54
|
+
"""
|
55
|
+
Invoke action lock
|
56
|
+
param body: The request body
|
57
|
+
param request_configuration: Configuration for the request such as headers, query parameters, and middleware options.
|
58
|
+
Returns: RequestInformation
|
59
|
+
"""
|
60
|
+
if body is None:
|
61
|
+
raise TypeError("body cannot be null.")
|
62
|
+
request_info = RequestInformation(Method.POST, self.url_template, self.path_parameters)
|
63
|
+
request_info.configure(request_configuration)
|
64
|
+
request_info.headers.try_add("Accept", "application/json")
|
65
|
+
request_info.set_content_from_parsable(self.request_adapter, "application/json", body)
|
66
|
+
return request_info
|
67
|
+
|
68
|
+
def with_url(self,raw_url: str) -> LockRequestBuilder:
|
69
|
+
"""
|
70
|
+
Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored.
|
71
|
+
param raw_url: The raw URL to use for the request builder.
|
72
|
+
Returns: LockRequestBuilder
|
73
|
+
"""
|
74
|
+
if raw_url is None:
|
75
|
+
raise TypeError("raw_url cannot be null.")
|
76
|
+
return LockRequestBuilder(self.request_adapter, raw_url)
|
77
|
+
|
78
|
+
@dataclass
|
79
|
+
class LockRequestBuilderPostRequestConfiguration(RequestConfiguration[QueryParameters]):
|
80
|
+
"""
|
81
|
+
Configuration for the request such as headers, query parameters, and middleware options.
|
82
|
+
"""
|
83
|
+
warn("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.", DeprecationWarning)
|
84
|
+
|
85
|
+
|
@@ -0,0 +1,77 @@
|
|
1
|
+
from __future__ import annotations
|
2
|
+
from dataclasses import dataclass, field
|
3
|
+
from kiota_abstractions.base_request_builder import BaseRequestBuilder
|
4
|
+
from kiota_abstractions.base_request_configuration import RequestConfiguration
|
5
|
+
from kiota_abstractions.default_query_parameters import QueryParameters
|
6
|
+
from kiota_abstractions.get_path_parameters import get_path_parameters
|
7
|
+
from kiota_abstractions.method import Method
|
8
|
+
from kiota_abstractions.request_adapter import RequestAdapter
|
9
|
+
from kiota_abstractions.request_information import RequestInformation
|
10
|
+
from kiota_abstractions.request_option import RequestOption
|
11
|
+
from kiota_abstractions.serialization import Parsable, ParsableFactory
|
12
|
+
from typing import Any, Callable, Dict, List, Optional, TYPE_CHECKING, Union
|
13
|
+
from warnings import warn
|
14
|
+
|
15
|
+
if TYPE_CHECKING:
|
16
|
+
from ......models.o_data_errors.o_data_error import ODataError
|
17
|
+
|
18
|
+
class PermanentDeleteRequestBuilder(BaseRequestBuilder):
|
19
|
+
"""
|
20
|
+
Provides operations to call the permanentDelete method.
|
21
|
+
"""
|
22
|
+
def __init__(self,request_adapter: RequestAdapter, path_parameters: Union[str, Dict[str, Any]]) -> None:
|
23
|
+
"""
|
24
|
+
Instantiates a new PermanentDeleteRequestBuilder and sets the default values.
|
25
|
+
param path_parameters: The raw url or the url-template parameters for the request.
|
26
|
+
param request_adapter: The request adapter to use to execute the requests.
|
27
|
+
Returns: None
|
28
|
+
"""
|
29
|
+
super().__init__(request_adapter, "{+baseurl}/storage/fileStorage/deletedContainers/{fileStorageContainer%2Did}/permanentDelete", path_parameters)
|
30
|
+
|
31
|
+
async def post(self,request_configuration: Optional[RequestConfiguration[QueryParameters]] = None) -> None:
|
32
|
+
"""
|
33
|
+
Invoke action permanentDelete
|
34
|
+
param request_configuration: Configuration for the request such as headers, query parameters, and middleware options.
|
35
|
+
Returns: None
|
36
|
+
"""
|
37
|
+
request_info = self.to_post_request_information(
|
38
|
+
request_configuration
|
39
|
+
)
|
40
|
+
from ......models.o_data_errors.o_data_error import ODataError
|
41
|
+
|
42
|
+
error_mapping: Dict[str, type[ParsableFactory]] = {
|
43
|
+
"XXX": ODataError,
|
44
|
+
}
|
45
|
+
if not self.request_adapter:
|
46
|
+
raise Exception("Http core is null")
|
47
|
+
return await self.request_adapter.send_no_response_content_async(request_info, error_mapping)
|
48
|
+
|
49
|
+
def to_post_request_information(self,request_configuration: Optional[RequestConfiguration[QueryParameters]] = None) -> RequestInformation:
|
50
|
+
"""
|
51
|
+
Invoke action permanentDelete
|
52
|
+
param request_configuration: Configuration for the request such as headers, query parameters, and middleware options.
|
53
|
+
Returns: RequestInformation
|
54
|
+
"""
|
55
|
+
request_info = RequestInformation(Method.POST, self.url_template, self.path_parameters)
|
56
|
+
request_info.configure(request_configuration)
|
57
|
+
request_info.headers.try_add("Accept", "application/json")
|
58
|
+
return request_info
|
59
|
+
|
60
|
+
def with_url(self,raw_url: str) -> PermanentDeleteRequestBuilder:
|
61
|
+
"""
|
62
|
+
Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored.
|
63
|
+
param raw_url: The raw URL to use for the request builder.
|
64
|
+
Returns: PermanentDeleteRequestBuilder
|
65
|
+
"""
|
66
|
+
if raw_url is None:
|
67
|
+
raise TypeError("raw_url cannot be null.")
|
68
|
+
return PermanentDeleteRequestBuilder(self.request_adapter, raw_url)
|
69
|
+
|
70
|
+
@dataclass
|
71
|
+
class PermanentDeleteRequestBuilderPostRequestConfiguration(RequestConfiguration[QueryParameters]):
|
72
|
+
"""
|
73
|
+
Configuration for the request such as headers, query parameters, and middleware options.
|
74
|
+
"""
|
75
|
+
warn("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.", DeprecationWarning)
|
76
|
+
|
77
|
+
|
@@ -0,0 +1,103 @@
|
|
1
|
+
from __future__ import annotations
|
2
|
+
from dataclasses import dataclass, field
|
3
|
+
from kiota_abstractions.base_request_builder import BaseRequestBuilder
|
4
|
+
from kiota_abstractions.base_request_configuration import RequestConfiguration
|
5
|
+
from kiota_abstractions.default_query_parameters import QueryParameters
|
6
|
+
from kiota_abstractions.get_path_parameters import get_path_parameters
|
7
|
+
from kiota_abstractions.method import Method
|
8
|
+
from kiota_abstractions.request_adapter import RequestAdapter
|
9
|
+
from kiota_abstractions.request_information import RequestInformation
|
10
|
+
from kiota_abstractions.request_option import RequestOption
|
11
|
+
from kiota_abstractions.serialization import Parsable, ParsableFactory
|
12
|
+
from typing import Any, Callable, Dict, List, Optional, TYPE_CHECKING, Union
|
13
|
+
from warnings import warn
|
14
|
+
|
15
|
+
if TYPE_CHECKING:
|
16
|
+
from .......models.o_data_errors.o_data_error import ODataError
|
17
|
+
|
18
|
+
class CountRequestBuilder(BaseRequestBuilder):
|
19
|
+
"""
|
20
|
+
Provides operations to count the resources in the collection.
|
21
|
+
"""
|
22
|
+
def __init__(self,request_adapter: RequestAdapter, path_parameters: Union[str, Dict[str, Any]]) -> None:
|
23
|
+
"""
|
24
|
+
Instantiates a new CountRequestBuilder and sets the default values.
|
25
|
+
param path_parameters: The raw url or the url-template parameters for the request.
|
26
|
+
param request_adapter: The request adapter to use to execute the requests.
|
27
|
+
Returns: None
|
28
|
+
"""
|
29
|
+
super().__init__(request_adapter, "{+baseurl}/storage/fileStorage/deletedContainers/{fileStorageContainer%2Did}/permissions/$count{?%24filter,%24search}", path_parameters)
|
30
|
+
|
31
|
+
async def get(self,request_configuration: Optional[RequestConfiguration[CountRequestBuilderGetQueryParameters]] = None) -> Optional[int]:
|
32
|
+
"""
|
33
|
+
Get the number of the resource
|
34
|
+
param request_configuration: Configuration for the request such as headers, query parameters, and middleware options.
|
35
|
+
Returns: Optional[int]
|
36
|
+
"""
|
37
|
+
request_info = self.to_get_request_information(
|
38
|
+
request_configuration
|
39
|
+
)
|
40
|
+
from .......models.o_data_errors.o_data_error import ODataError
|
41
|
+
|
42
|
+
error_mapping: Dict[str, type[ParsableFactory]] = {
|
43
|
+
"XXX": ODataError,
|
44
|
+
}
|
45
|
+
if not self.request_adapter:
|
46
|
+
raise Exception("Http core is null")
|
47
|
+
return await self.request_adapter.send_primitive_async(request_info, "int", error_mapping)
|
48
|
+
|
49
|
+
def to_get_request_information(self,request_configuration: Optional[RequestConfiguration[CountRequestBuilderGetQueryParameters]] = None) -> RequestInformation:
|
50
|
+
"""
|
51
|
+
Get the number of the resource
|
52
|
+
param request_configuration: Configuration for the request such as headers, query parameters, and middleware options.
|
53
|
+
Returns: RequestInformation
|
54
|
+
"""
|
55
|
+
request_info = RequestInformation(Method.GET, self.url_template, self.path_parameters)
|
56
|
+
request_info.configure(request_configuration)
|
57
|
+
request_info.headers.try_add("Accept", "text/plain;q=0.9")
|
58
|
+
return request_info
|
59
|
+
|
60
|
+
def with_url(self,raw_url: str) -> CountRequestBuilder:
|
61
|
+
"""
|
62
|
+
Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored.
|
63
|
+
param raw_url: The raw URL to use for the request builder.
|
64
|
+
Returns: CountRequestBuilder
|
65
|
+
"""
|
66
|
+
if raw_url is None:
|
67
|
+
raise TypeError("raw_url cannot be null.")
|
68
|
+
return CountRequestBuilder(self.request_adapter, raw_url)
|
69
|
+
|
70
|
+
@dataclass
|
71
|
+
class CountRequestBuilderGetQueryParameters():
|
72
|
+
"""
|
73
|
+
Get the number of the resource
|
74
|
+
"""
|
75
|
+
def get_query_parameter(self,original_name: str) -> str:
|
76
|
+
"""
|
77
|
+
Maps the query parameters names to their encoded names for the URI template parsing.
|
78
|
+
param original_name: The original query parameter name in the class.
|
79
|
+
Returns: str
|
80
|
+
"""
|
81
|
+
if original_name is None:
|
82
|
+
raise TypeError("original_name cannot be null.")
|
83
|
+
if original_name == "filter":
|
84
|
+
return "%24filter"
|
85
|
+
if original_name == "search":
|
86
|
+
return "%24search"
|
87
|
+
return original_name
|
88
|
+
|
89
|
+
# Filter items by property values
|
90
|
+
filter: Optional[str] = None
|
91
|
+
|
92
|
+
# Search items by search phrases
|
93
|
+
search: Optional[str] = None
|
94
|
+
|
95
|
+
|
96
|
+
@dataclass
|
97
|
+
class CountRequestBuilderGetRequestConfiguration(RequestConfiguration[CountRequestBuilderGetQueryParameters]):
|
98
|
+
"""
|
99
|
+
Configuration for the request such as headers, query parameters, and middleware options.
|
100
|
+
"""
|
101
|
+
warn("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.", DeprecationWarning)
|
102
|
+
|
103
|
+
|
@@ -0,0 +1,62 @@
|
|
1
|
+
from __future__ import annotations
|
2
|
+
from dataclasses import dataclass, field
|
3
|
+
from kiota_abstractions.serialization import AdditionalDataHolder, Parsable, ParseNode, SerializationWriter
|
4
|
+
from kiota_abstractions.store import BackedModel, BackingStore, BackingStoreFactorySingleton
|
5
|
+
from typing import Any, Callable, Dict, List, Optional, TYPE_CHECKING, Union
|
6
|
+
|
7
|
+
if TYPE_CHECKING:
|
8
|
+
from ........models.drive_recipient import DriveRecipient
|
9
|
+
|
10
|
+
@dataclass
|
11
|
+
class GrantPostRequestBody(AdditionalDataHolder, BackedModel, Parsable):
|
12
|
+
# Stores model information.
|
13
|
+
backing_store: BackingStore = field(default_factory=BackingStoreFactorySingleton(backing_store_factory=None).backing_store_factory.create_backing_store, repr=False)
|
14
|
+
|
15
|
+
# Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
16
|
+
additional_data: Dict[str, Any] = field(default_factory=dict)
|
17
|
+
# The recipients property
|
18
|
+
recipients: Optional[List[DriveRecipient]] = None
|
19
|
+
# The roles property
|
20
|
+
roles: Optional[List[str]] = None
|
21
|
+
|
22
|
+
@staticmethod
|
23
|
+
def create_from_discriminator_value(parse_node: ParseNode) -> GrantPostRequestBody:
|
24
|
+
"""
|
25
|
+
Creates a new instance of the appropriate class based on discriminator value
|
26
|
+
param parse_node: The parse node to use to read the discriminator value and create the object
|
27
|
+
Returns: GrantPostRequestBody
|
28
|
+
"""
|
29
|
+
if parse_node is None:
|
30
|
+
raise TypeError("parse_node cannot be null.")
|
31
|
+
return GrantPostRequestBody()
|
32
|
+
|
33
|
+
def get_field_deserializers(self,) -> Dict[str, Callable[[ParseNode], None]]:
|
34
|
+
"""
|
35
|
+
The deserialization information for the current model
|
36
|
+
Returns: Dict[str, Callable[[ParseNode], None]]
|
37
|
+
"""
|
38
|
+
from ........models.drive_recipient import DriveRecipient
|
39
|
+
|
40
|
+
from ........models.drive_recipient import DriveRecipient
|
41
|
+
|
42
|
+
fields: Dict[str, Callable[[Any], None]] = {
|
43
|
+
"recipients": lambda n : setattr(self, 'recipients', n.get_collection_of_object_values(DriveRecipient)),
|
44
|
+
"roles": lambda n : setattr(self, 'roles', n.get_collection_of_primitive_values(str)),
|
45
|
+
}
|
46
|
+
return fields
|
47
|
+
|
48
|
+
def serialize(self,writer: SerializationWriter) -> None:
|
49
|
+
"""
|
50
|
+
Serializes information the current object
|
51
|
+
param writer: Serialization writer to use to serialize this model
|
52
|
+
Returns: None
|
53
|
+
"""
|
54
|
+
if writer is None:
|
55
|
+
raise TypeError("writer cannot be null.")
|
56
|
+
from ........models.drive_recipient import DriveRecipient
|
57
|
+
|
58
|
+
writer.write_collection_of_object_values("recipients", self.recipients)
|
59
|
+
writer.write_collection_of_primitive_values("roles", self.roles)
|
60
|
+
writer.write_additional_data_value(self.additional_data)
|
61
|
+
|
62
|
+
|