From 949f683a5d47ade05d55744eb0fe93336471057a Mon Sep 17 00:00:00 2001 From: vgrem Date: Sun, 8 Oct 2023 10:33:15 +0300 Subject: [PATCH] refactorings and type hints for collection types --- examples/sharepoint/fields/get_from_list.py | 7 +++---- examples/sharepoint/fields/get_from_web.py | 7 +++---- examples/sharepoint/permissions/get_for_site.py | 9 +++++---- generator/metadata/SharePoint.xml | 2 +- office365/sharepoint/activities/entity.py | 4 ++-- office365/sharepoint/activities/logger.py | 4 ++-- .../sharepoint/activities/tracked_item_service.py | 4 ++-- .../administration/analytics/usage_service.py | 4 ++-- .../sharepoint/administration/web_application.py | 8 ++++---- office365/sharepoint/administration/web_service.py | 8 ++++---- office365/sharepoint/alerts/alert.py | 4 ++-- office365/sharepoint/alerts/collection.py | 4 ++-- office365/sharepoint/analytics/usage_entry.py | 4 ++-- office365/sharepoint/appprincipal/credential.py | 4 ++-- .../sharepoint/appprincipal/identity_provider.py | 4 ++-- office365/sharepoint/appprincipal/manager.py | 4 ++-- office365/sharepoint/appprincipal/name.py | 4 ++-- office365/sharepoint/apps/app_collection.py | 4 ++-- office365/sharepoint/apps/license_manager.py | 4 ++-- office365/sharepoint/apps/solution_exporter.py | 4 ++-- office365/sharepoint/apps/user_solution.py | 4 ++-- office365/sharepoint/attachments/attachment.py | 4 ++-- office365/sharepoint/attachments/collection.py | 4 ++-- office365/sharepoint/audit/audit.py | 4 ++-- .../sharepoint/authpolicy/events/auth_event.py | 4 ++-- .../sharepoint/businessdata/app_bdc_catalog.py | 4 ++-- .../securestore/connection_settings.py | 4 ++-- office365/sharepoint/campaigns/campaigns.py | 4 ++-- office365/sharepoint/changes/change.py | 4 ++-- office365/sharepoint/changes/collection.py | 4 ++-- office365/sharepoint/client_context.py | 4 ++-- .../clientsidecomponent/component_context_info.py | 4 ++-- .../clientsidecomponent/hostedapps/add_response.py | 4 ++-- .../clientsidecomponent/hostedapps/app.py | 4 ++-- .../clientsidecomponent/hostedapps/manager.py | 4 ++-- .../clientsidecomponent/storage_entity.py | 4 ++-- office365/sharepoint/comments/collection.py | 4 ++-- office365/sharepoint/comments/comment.py | 8 ++++---- office365/sharepoint/compliance/store_proxy.py | 4 ++-- .../contentcenter/machinelearning/enabled.py | 4 ++-- .../contentcenter/machinelearning/hub.py | 4 ++-- .../machinelearning/models/collection.py | 4 ++-- .../machinelearning/models/entity_data.py | 4 ++-- .../contentcenter/machinelearning/models/model.py | 4 ++-- .../machinelearning/publications/publication.py | 4 ++-- .../machinelearning/publications/result.py | 4 ++-- .../machinelearning/samples/collection.py | 4 ++-- .../machinelearning/samples/entity_data.py | 4 ++-- .../machinelearning/samples/sample.py | 4 ++-- .../machinelearning/workitems/collection.py | 4 ++-- .../machinelearning/workitems/item.py | 4 ++-- .../contentcenter/syntex_models_landing_info.py | 4 ++-- office365/sharepoint/contenttypes/collection.py | 4 ++-- office365/sharepoint/contenttypes/content_type.py | 4 ++-- .../contenttypes/fieldlinks/collection.py | 4 ++-- .../contenttypes/fieldlinks/field_link.py | 4 ++-- .../sharepoint/convergence/consumer_permissions.py | 4 ++-- office365/sharepoint/customactions/action.py | 4 ++-- office365/sharepoint/directory/group.py | 10 +++++----- .../sharepoint/directory/group_and_user_status.py | 4 ++-- office365/sharepoint/directory/helper.py | 14 +++++++------- office365/sharepoint/directory/link.py | 4 ++-- office365/sharepoint/directory/members_info.py | 4 ++-- .../sharepoint/directory/membership_result.py | 4 ++-- office365/sharepoint/directory/my_groups_result.py | 4 ++-- .../sharepoint/directory/provider/provider.py | 4 ++-- office365/sharepoint/directory/session.py | 4 ++-- office365/sharepoint/directory/user.py | 4 ++-- .../sharepoint/documentmanagement/document_id.py | 4 ++-- office365/sharepoint/{base_entity.py => entity.py} | 2 +- ...e_entity_collection.py => entity_collection.py} | 2 +- office365/sharepoint/eventreceivers/definition.py | 4 ++-- .../eventreceivers/definition_collection.py | 4 ++-- office365/sharepoint/features/collection.py | 4 ++-- .../sharepoint/features/definitions/collection.py | 4 ++-- .../sharepoint/features/definitions/definition.py | 4 ++-- office365/sharepoint/features/feature.py | 4 ++-- office365/sharepoint/fields/collection.py | 4 ++-- office365/sharepoint/fields/field.py | 4 ++-- office365/sharepoint/fields/related_field.py | 4 ++-- .../sharepoint/fields/related_field_collection.py | 4 ++-- office365/sharepoint/fields/string_values.py | 4 ++-- office365/sharepoint/files/checked_out_file.py | 4 ++-- .../files/checked_out_file_collection.py | 4 ++-- office365/sharepoint/files/collection.py | 4 ++-- office365/sharepoint/files/file.py | 8 ++++---- .../sharepoint/files/recent_file_collection.py | 4 ++-- office365/sharepoint/files/versions/collection.py | 4 ++-- office365/sharepoint/files/versions/event.py | 4 ++-- office365/sharepoint/files/versions/version.py | 4 ++-- .../sharepoint/flows/synchronization_result.py | 4 ++-- office365/sharepoint/folders/collection.py | 4 ++-- office365/sharepoint/folders/coloring.py | 4 ++-- office365/sharepoint/folders/folder.py | 4 ++-- office365/sharepoint/forms/collection.py | 4 ++-- office365/sharepoint/forms/customization.py | 4 ++-- office365/sharepoint/forms/form.py | 4 ++-- office365/sharepoint/largeoperation/operation.py | 4 ++-- office365/sharepoint/likes/liked_by_information.py | 8 ++++---- office365/sharepoint/likes/user_entity.py | 4 ++-- office365/sharepoint/listhome/favorite_lists.py | 4 ++-- office365/sharepoint/listitems/collection.py | 4 ++-- office365/sharepoint/listitems/listitem.py | 2 +- .../sharepoint/listitems/versions/collection.py | 4 ++-- office365/sharepoint/listitems/versions/version.py | 4 ++-- office365/sharepoint/lists/bloom_filter.py | 4 ++-- office365/sharepoint/lists/collection.py | 4 ++-- office365/sharepoint/lists/creatables_info.py | 4 ++-- office365/sharepoint/lists/currency.py | 4 ++-- office365/sharepoint/lists/template.py | 4 ++-- office365/sharepoint/lists/template_collection.py | 4 ++-- office365/sharepoint/logger/logFileInfo.py | 4 ++-- .../sharepoint/logger/logFileInfoCollection.py | 4 ++-- office365/sharepoint/logger/log_export.py | 4 ++-- office365/sharepoint/marketplace/app_metadata.py | 4 ++-- .../marketplace/app_metadata_collection.py | 4 ++-- .../teams_package_download.py | 4 ++-- .../sitecollection/appcatalog/accessor.py | 4 ++-- .../sitecollection/appcatalog/allowed_item.py | 4 ++-- .../sitecollection/appcatalog/allowed_items.py | 4 ++-- .../marketplace/tenant/appcatalog/accessor.py | 4 ++-- office365/sharepoint/microfeed/attachment_store.py | 4 ++-- office365/sharepoint/microfeed/data.py | 4 ++-- office365/sharepoint/microfeed/manager.py | 4 ++-- office365/sharepoint/microservice/manager.py | 4 ++-- office365/sharepoint/migration/job_status.py | 4 ++-- .../migrationcenter/common/task_entity_data.py | 4 ++-- .../migrationcenter/service/credential.py | 4 ++-- .../migrationcenter/service/properties.py | 4 ++-- .../sharepoint/migrationcenter/service/services.py | 4 ++-- office365/sharepoint/mount/folder_info.py | 4 ++-- office365/sharepoint/mount/point.py | 4 ++-- office365/sharepoint/mount/service.py | 4 ++-- office365/sharepoint/multigeo/unified_group.py | 4 ++-- .../navigation/home_site_navigation_settings.py | 4 ++-- .../sharepoint/navigation/metadata_settings.py | 4 ++-- office365/sharepoint/navigation/navigation.py | 4 ++-- .../sharepoint/navigation/navigation_service.py | 4 ++-- office365/sharepoint/navigation/node.py | 4 ++-- office365/sharepoint/navigation/node_collection.py | 4 ++-- office365/sharepoint/oauth/authentication.py | 4 ++-- office365/sharepoint/oauth/native_client.py | 4 ++-- office365/sharepoint/onboarding/job_entity_data.py | 4 ++-- office365/sharepoint/orgnewssite/api.py | 4 ++-- office365/sharepoint/packaging/app_details.py | 4 ++-- .../pageinstrumentation/click_manager.py | 4 ++-- .../permissions/irm/effective_settings.py | 4 ++-- .../sharepoint/permissions/irm/file_settings.py | 4 ++-- office365/sharepoint/permissions/irm/settings.py | 4 ++-- .../permissions/roles/assignments/assignment.py | 4 ++-- .../permissions/roles/assignments/collection.py | 4 ++-- .../permissions/roles/definitions/collection.py | 4 ++-- .../permissions/roles/definitions/definition.py | 4 ++-- .../sharepoint/permissions/securable_object.py | 11 +++++------ office365/sharepoint/permissions/utility.py | 4 ++-- office365/sharepoint/photos/migration.py | 4 ++-- office365/sharepoint/policy/dlp_policy_tip.py | 4 ++-- office365/sharepoint/policy/evaluation_info.py | 4 ++-- .../sharepoint/portal/collaboration_mailbox.py | 4 ++-- .../sharepoint/portal/community_moderation.py | 4 ++-- office365/sharepoint/portal/groups/service.py | 4 ++-- .../sharepoint/portal/home/service_context.py | 4 ++-- .../portal/home/service_context_builder.py | 4 ++-- office365/sharepoint/portal/hub_sites_utility.py | 4 ++-- office365/sharepoint/portal/linkedsites/manager.py | 4 ++-- .../sharepoint/portal/mysite_recommendations.py | 4 ++-- office365/sharepoint/portal/organization_news.py | 4 ++-- office365/sharepoint/portal/rating_settings.py | 4 ++-- office365/sharepoint/portal/sites/icon_manager.py | 4 ++-- office365/sharepoint/portal/sites/manager.py | 4 ++-- office365/sharepoint/portal/suite_nav_data.py | 4 ++-- office365/sharepoint/portal/theme_manager.py | 4 ++-- .../userprofiles/documents_shared_with_group.py | 4 ++-- .../userprofiles/documents_shared_with_me.py | 4 ++-- .../sharepoint/principal/groups/collection.py | 6 +++--- office365/sharepoint/principal/principal.py | 4 ++-- office365/sharepoint/principal/users/collection.py | 4 ++-- .../publishing/announcements/controller.py | 4 ++-- .../sharepoint/publishing/customproperties/base.py | 4 ++-- .../publishing/diagnostics/controller.py | 4 ++-- office365/sharepoint/publishing/embed_data_v1.py | 4 ++-- office365/sharepoint/publishing/embed_service.py | 4 ++-- office365/sharepoint/publishing/highlights_info.py | 4 ++-- .../structural_navigation_cache_wrapper.py | 4 ++-- .../publishing/pagecopywithassets/response.py | 4 ++-- office365/sharepoint/publishing/pages/metadata.py | 4 ++-- .../publishing/pages/metadata_collection.py | 4 ++-- .../sharepoint/publishing/pages/move_response.py | 4 ++-- .../publishing/pages/reposts/collection.py | 4 ++-- office365/sharepoint/publishing/pages/service.py | 4 ++-- .../publishing/pages/topics/collection.py | 4 ++-- .../publishing/personmagazine/person_magazine.py | 4 ++-- .../sharepoint/publishing/point/site_manager.py | 4 ++-- .../sharepoint/publishing/point/site_status.py | 4 ++-- .../publishing/portallaunch/waves_manager.py | 4 ++-- .../sharepoint/publishing/primary_city_time.py | 4 ++-- office365/sharepoint/publishing/rich_sharing.py | 4 ++-- office365/sharepoint/publishing/search.py | 4 ++-- .../publishing/sites/communication/site.py | 4 ++-- office365/sharepoint/publishing/video/channel.py | 4 ++-- .../publishing/video/channel_collection.py | 4 ++-- office365/sharepoint/publishing/video/item.py | 4 ++-- .../sharepoint/publishing/video/item_collection.py | 4 ++-- .../publishing/video/service_discoverer.py | 4 ++-- .../sharepoint/publishing/video/service_manager.py | 4 ++-- .../sharepoint/pushnotifications/collection.py | 4 ++-- .../sharepoint/pushnotifications/subscriber.py | 4 ++-- office365/sharepoint/recyclebin/item.py | 4 ++-- office365/sharepoint/recyclebin/item_collection.py | 4 ++-- office365/sharepoint/reputationmodel/reputation.py | 4 ++-- office365/sharepoint/request_user_context.py | 4 ++-- .../search/administration/document_crawl_log.py | 4 ++-- .../site_content_processing_info_provider.py | 4 ++-- .../administration/site_me_ta_info_provider.py | 4 ++-- .../tenant_crawl_versions_info_provider.py | 4 ++-- .../sharepoint/search/analytics/signal_store.py | 4 ++-- .../search/query/personalization_data.py | 4 ++-- .../sharepoint/search/query/sort/collection.py | 4 ++-- office365/sharepoint/search/ranking_labeling.py | 4 ++-- .../search/reordering_rule_collection.py | 4 ++-- office365/sharepoint/search/service.py | 4 ++-- office365/sharepoint/search/setting.py | 4 ++-- .../sharepoint/securestore/target_application.py | 4 ++-- .../securestore/target_application_field.py | 4 ++-- office365/sharepoint/server_settings.py | 4 ++-- office365/sharepoint/sharing/document_manager.py | 4 ++-- office365/sharepoint/sharing/information.py | 4 ++-- .../sharing/object_sharing_information.py | 10 +++++----- .../sharing/object_sharing_information_user.py | 4 ++-- .../sharepoint/sharing/object_sharing_settings.py | 4 ++-- .../sharepoint/sharing/permission_information.py | 4 ++-- office365/sharepoint/sharing/personal_web.py | 4 ++-- office365/sharepoint/sharing/picker_settings.py | 4 ++-- office365/sharepoint/sharing/result.py | 4 ++-- .../sharing/securable_object_extensions.py | 4 ++-- .../sharepoint/sharing/shared_document_info.py | 4 ++-- .../sharing/sharepoint_sharing_settings.py | 4 ++-- .../sharing/site_sharing_report_helper.py | 4 ++-- office365/sharepoint/sharing/utility.py | 4 ++-- .../sharepoint/sharing/web_sharing_manager.py | 4 ++-- .../sitedesigns/design_package_menu_contents.py | 4 ++-- office365/sharepoint/sitedesigns/principal.py | 4 ++-- office365/sharepoint/sitedesigns/run.py | 4 ++-- office365/sharepoint/sitehealth/summary.py | 4 ++-- office365/sharepoint/sites/language_collection.py | 4 ++-- office365/sharepoint/sites/site.py | 8 ++++---- office365/sharepoint/sites/sph_site.py | 4 ++-- office365/sharepoint/sites/team_site_data.py | 4 ++-- .../sharepoint/sites/version_policy_manager.py | 4 ++-- office365/sharepoint/sitescripts/utility.py | 8 ++++---- .../sharepoint/social/announcement_manager.py | 4 ++-- office365/sharepoint/social/feed/manager.py | 4 ++-- office365/sharepoint/social/feed/rest.py | 4 ++-- office365/sharepoint/social/feed/rest_manager.py | 4 ++-- office365/sharepoint/social/following/manager.py | 4 ++-- .../sharepoint/social/following/rest_manager.py | 4 ++-- office365/sharepoint/social/rest_actor.py | 4 ++-- office365/sharepoint/social/rest_thread.py | 4 ++-- office365/sharepoint/social/switch.py | 4 ++-- .../sharepoint/storagemetrics/storage_metrics.py | 4 ++-- office365/sharepoint/teams/channel.py | 4 ++-- office365/sharepoint/teams/channel_manager.py | 4 ++-- .../sharepoint/tenant/administration/endpoints.py | 4 ++-- .../tenant/administration/hubsites/collection.py | 4 ++-- .../tenant/administration/hubsites/hub_site.py | 4 ++-- .../tenant/administration/hubsites/properties.py | 4 ++-- .../administration/insights/top_files_sharing.py | 4 ++-- .../internal/web_appservice_principal.py | 4 ++-- .../administration/response_message_center.py | 4 ++-- .../administration/response_service_health.py | 4 ++-- .../tenant/administration/settings_service.py | 4 ++-- .../tenant/administration/sites/properties.py | 4 ++-- .../administration/sites/properties_collection.py | 4 ++-- .../sharepoint/tenant/administration/tenant.py | 8 ++++---- .../tenant/administration/theme_properties.py | 4 ++-- .../administration/webs/templates/collection.py | 4 ++-- office365/sharepoint/tenant/apps/instance.py | 4 ++-- .../tenant/apps/user_experience_state.py | 4 ++-- office365/sharepoint/tenant/apps/utility.py | 4 ++-- office365/sharepoint/tenant/cdn_api.py | 4 ++-- .../tenant/management/externalusers/collection.py | 4 ++-- .../management/externalusers/external_user.py | 4 ++-- .../tenant/management/externalusers/results/get.py | 4 ++-- .../management/externalusers/results/remove.py | 4 ++-- .../externalusers/results/session_revocation.py | 4 ++-- .../tenant/management/office365_tenant.py | 4 ++-- office365/sharepoint/tenant/settings.py | 4 ++-- office365/sharepoint/translation/job.py | 4 ++-- office365/sharepoint/translation/job_status.py | 4 ++-- .../translation/notification_recipient_users.py | 4 ++-- .../sharepoint/translation/status_collection.py | 4 ++-- .../sharepoint/translation/sync_translator.py | 4 ++-- office365/sharepoint/translation/user_resource.py | 4 ++-- .../sharepoint/translation/variations_timer_job.py | 4 ++-- office365/sharepoint/types/property_values.py | 4 ++-- .../peoplepicker/web_service_interface.py | 4 ++-- office365/sharepoint/usercustomactions/action.py | 4 ++-- .../sharepoint/usercustomactions/collection.py | 4 ++-- .../sharepoint/userprofiles/followed_content.py | 4 ++-- office365/sharepoint/userprofiles/hash_tag.py | 4 ++-- office365/sharepoint/userprofiles/my_site_links.py | 4 ++-- .../userprofiles/mysite/dismiss_status_text.py | 4 ++-- .../sharepoint/userprofiles/people_manager.py | 13 ++++++------- .../sharepoint/userprofiles/person_properties.py | 4 ++-- .../sharepoint/userprofiles/personal_cache.py | 4 ++-- .../sharepoint/userprofiles/profile_image_store.py | 4 ++-- .../sharepoint/userprofiles/promoted_sites.py | 4 ++-- .../sharepoint/userprofiles/properties_for_user.py | 4 ++-- .../userprofiles/sharedwithme/document.py | 4 ++-- .../userprofiles/sharedwithme/item_collection.py | 4 ++-- .../sharepoint/userprofiles/sharedwithme/items.py | 8 ++++---- office365/sharepoint/userprofiles/user_profile.py | 4 ++-- office365/sharepoint/utilities/move_copy_util.py | 4 ++-- office365/sharepoint/utilities/upload_status.py | 4 ++-- office365/sharepoint/utilities/utility.py | 4 ++-- office365/sharepoint/views/collection.py | 4 ++-- office365/sharepoint/views/field_collection.py | 4 ++-- office365/sharepoint/views/view.py | 4 ++-- office365/sharepoint/viva/app_configuration.py | 4 ++-- office365/sharepoint/viva/employee_engagement.py | 4 ++-- .../viva/employee_experience_controller.py | 4 ++-- office365/sharepoint/viva/home.py | 4 ++-- office365/sharepoint/viva/site_manager.py | 4 ++-- office365/sharepoint/webhooks/subscription.py | 4 ++-- .../sharepoint/webhooks/subscription_collection.py | 4 ++-- office365/sharepoint/webparts/client/collection.py | 4 ++-- office365/sharepoint/webparts/client/webpart.py | 4 ++-- office365/sharepoint/webparts/definition.py | 4 ++-- .../sharepoint/webparts/definition_collection.py | 4 ++-- office365/sharepoint/webparts/limited_manager.py | 4 ++-- office365/sharepoint/webparts/webpart.py | 4 ++-- office365/sharepoint/webs/collection.py | 4 ++-- office365/sharepoint/webs/information.py | 4 ++-- .../sharepoint/webs/information_collection.py | 4 ++-- .../sharepoint/webs/modernize_homepage_result.py | 4 ++-- office365/sharepoint/webs/multilingual_settings.py | 8 ++++---- office365/sharepoint/webs/regional_settings.py | 4 ++-- office365/sharepoint/webs/template.py | 4 ++-- office365/sharepoint/webs/template_collection.py | 4 ++-- office365/sharepoint/webs/theme_info.py | 4 ++-- office365/sharepoint/webs/time_zone.py | 8 ++++---- office365/sharepoint/webs/web.py | 9 ++++----- office365/sharepoint/workflow/association.py | 4 ++-- office365/sharepoint/workflow/template.py | 4 ++-- office365/sharepoint/workflowservices/instance.py | 4 ++-- .../workflowservices/instance_service.py | 8 ++++---- office365/sharepoint/workflowservices/manager.py | 4 ++-- office365/sharepoint/yammer/wac_api.py | 4 ++-- 348 files changed, 742 insertions(+), 746 deletions(-) rename office365/sharepoint/{base_entity.py => entity.py} (97%) rename office365/sharepoint/{base_entity_collection.py => entity_collection.py} (85%) diff --git a/examples/sharepoint/fields/get_from_list.py b/examples/sharepoint/fields/get_from_list.py index 0568272de..50b7a8122 100644 --- a/examples/sharepoint/fields/get_from_list.py +++ b/examples/sharepoint/fields/get_from_list.py @@ -1,13 +1,12 @@ """ -This example retrieves all of the fields in a SharePoint list. +This example retrieves all fields in a SharePoint list. """ from office365.sharepoint.client_context import ClientContext -from office365.sharepoint.fields.field import Field from tests import test_client_credentials, test_team_site_url client = ClientContext(test_team_site_url).with_credentials(test_client_credentials) target_list = client.web.lists.get_by_title("Site Pages") fields = target_list.fields.get().execute_query() -for f in fields: # type: Field - print(f"Field name {f.internal_name}") +for field in fields: + print("Field name {0}".format(field.internal_name)) diff --git a/examples/sharepoint/fields/get_from_web.py b/examples/sharepoint/fields/get_from_web.py index d407b7f16..671de5432 100644 --- a/examples/sharepoint/fields/get_from_web.py +++ b/examples/sharepoint/fields/get_from_web.py @@ -1,12 +1,11 @@ """ -This example retrieves all of the fields in a SharePoint site. +This example retrieves all fields in a SharePoint site. """ from office365.sharepoint.client_context import ClientContext -from office365.sharepoint.fields.field import Field from tests import test_client_credentials, test_team_site_url client = ClientContext(test_team_site_url).with_credentials(test_client_credentials) web_fields = client.web.fields.get().execute_query() -for f in web_fields: # type: Field - print(f"Field name {f.internal_name}") +for f in web_fields: + print("Field name {0}".format(f.internal_name)) diff --git a/examples/sharepoint/permissions/get_for_site.py b/examples/sharepoint/permissions/get_for_site.py index 4565f8cba..33aead646 100644 --- a/examples/sharepoint/permissions/get_for_site.py +++ b/examples/sharepoint/permissions/get_for_site.py @@ -1,12 +1,13 @@ +""" +Demonstrates how to retrieve site groups along with users +""" from office365.sharepoint.client_context import ClientContext -from office365.sharepoint.principal.groups.group import Group -from office365.sharepoint.principal.users.user import User from tests import test_client_credentials, test_team_site_url ctx = ClientContext(test_team_site_url).with_credentials(test_client_credentials) site_groups = ctx.web.site_groups.expand(["Users"]).get().execute_query() -for g in site_groups: # type: Group +for g in site_groups: print("Group name: {0}".format(g.login_name)) - for u in g.users: # type: User + for u in g.users: print("User name: {0}".format(u.login_name)) diff --git a/generator/metadata/SharePoint.xml b/generator/metadata/SharePoint.xml index ea843a21c..e08d5b79a 100644 --- a/generator/metadata/SharePoint.xml +++ b/generator/metadata/SharePoint.xml @@ -38679,6 +38679,7 @@ + @@ -38729,7 +38730,6 @@ - diff --git a/office365/sharepoint/activities/entity.py b/office365/sharepoint/activities/entity.py index d2417cec1..095a2b579 100644 --- a/office365/sharepoint/activities/entity.py +++ b/office365/sharepoint/activities/entity.py @@ -3,11 +3,11 @@ from office365.sharepoint.activities.facets.coalesced import CoalescedFacet from office365.sharepoint.activities.facets.in_doc import InDocFacet from office365.sharepoint.activities.facets.resource import ResourceFacet -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.sharing.principal import Principal -class SPActivityEntity(BaseEntity): +class SPActivityEntity(Entity): """""" @property diff --git a/office365/sharepoint/activities/logger.py b/office365/sharepoint/activities/logger.py index 2bb2c134d..aa5ecfae7 100644 --- a/office365/sharepoint/activities/logger.py +++ b/office365/sharepoint/activities/logger.py @@ -1,8 +1,8 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class ActivityLogger(BaseEntity): +class ActivityLogger(Entity): def log_activity( self, operation, diff --git a/office365/sharepoint/activities/tracked_item_service.py b/office365/sharepoint/activities/tracked_item_service.py index b1e2f7dea..2d211b42f 100644 --- a/office365/sharepoint/activities/tracked_item_service.py +++ b/office365/sharepoint/activities/tracked_item_service.py @@ -3,10 +3,10 @@ from office365.sharepoint.activities.tracked_item_updates_request import ( TrackedItemUpdatesRequest, ) -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class TrackedItemService(BaseEntity): +class TrackedItemService(Entity): @staticmethod def get_tracked_item_updates_for_user(context): """ diff --git a/office365/sharepoint/administration/analytics/usage_service.py b/office365/sharepoint/administration/analytics/usage_service.py index 5c54cf084..80ef9de75 100644 --- a/office365/sharepoint/administration/analytics/usage_service.py +++ b/office365/sharepoint/administration/analytics/usage_service.py @@ -1,9 +1,9 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SPAnalyticsUsageService(BaseEntity): +class SPAnalyticsUsageService(Entity): """Represents the entry point for the Event REST service exposed through CSOM""" def __init__(self, context): diff --git a/office365/sharepoint/administration/web_application.py b/office365/sharepoint/administration/web_application.py index 0b39a9478..ebf25c6f4 100644 --- a/office365/sharepoint/administration/web_application.py +++ b/office365/sharepoint/administration/web_application.py @@ -1,11 +1,11 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity import Entity +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.sites.site import Site -class WebApplication(BaseEntity): +class WebApplication(Entity): @staticmethod def lookup(context, request_uri): """ @@ -31,7 +31,7 @@ def outbound_mail_sender_address(self): def sites(self): return self.properties.get( "Sites", - BaseEntityCollection( + EntityCollection( self.context, Site, ResourcePath("Sites", self.resource_path) ), ) diff --git a/office365/sharepoint/administration/web_service.py b/office365/sharepoint/administration/web_service.py index b08434b16..3200e6c74 100644 --- a/office365/sharepoint/administration/web_service.py +++ b/office365/sharepoint/administration/web_service.py @@ -1,11 +1,11 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery from office365.sharepoint.administration.web_application import WebApplication -from office365.sharepoint.base_entity import BaseEntity -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity import Entity +from office365.sharepoint.entity_collection import EntityCollection -class SPWebService(BaseEntity): +class SPWebService(Entity): @staticmethod def content_service(context): """ @@ -23,7 +23,7 @@ def content_service(context): def web_applications(self): return self.properties.get( "WebApplications", - BaseEntityCollection( + EntityCollection( self.context, WebApplication, ResourcePath("WebApplications", self.resource_path), diff --git a/office365/sharepoint/alerts/alert.py b/office365/sharepoint/alerts/alert.py index 6f432d7f3..902a50355 100644 --- a/office365/sharepoint/alerts/alert.py +++ b/office365/sharepoint/alerts/alert.py @@ -1,8 +1,8 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class Alert(BaseEntity): +class Alert(Entity): """ Represents an alert, which generates periodic e-mail notifications sent to a user about the list, list item, document, or document library to which the alert applies. SP.Alert provides information about the alert, diff --git a/office365/sharepoint/alerts/collection.py b/office365/sharepoint/alerts/collection.py index 4f6782735..cffff17be 100644 --- a/office365/sharepoint/alerts/collection.py +++ b/office365/sharepoint/alerts/collection.py @@ -2,10 +2,10 @@ from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.service_operation import ServiceOperationQuery from office365.sharepoint.alerts.alert import Alert -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection -class AlertCollection(BaseEntityCollection): +class AlertCollection(EntityCollection): """Content Type resource collection""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/analytics/usage_entry.py b/office365/sharepoint/analytics/usage_entry.py index 960b9aea6..82982390d 100644 --- a/office365/sharepoint/analytics/usage_entry.py +++ b/office365/sharepoint/analytics/usage_entry.py @@ -1,8 +1,8 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class AnalyticsUsageEntry(BaseEntity): +class AnalyticsUsageEntry(Entity): """Specifies an analytics usage entry to log user or system events""" @staticmethod diff --git a/office365/sharepoint/appprincipal/credential.py b/office365/sharepoint/appprincipal/credential.py index 9a85d95a1..ec93d661c 100644 --- a/office365/sharepoint/appprincipal/credential.py +++ b/office365/sharepoint/appprincipal/credential.py @@ -1,8 +1,8 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class AppPrincipalCredential(BaseEntity): +class AppPrincipalCredential(Entity): """Represents a credential belonging to an app principal.""" @staticmethod diff --git a/office365/sharepoint/appprincipal/identity_provider.py b/office365/sharepoint/appprincipal/identity_provider.py index 553712f1b..4583dde5c 100644 --- a/office365/sharepoint/appprincipal/identity_provider.py +++ b/office365/sharepoint/appprincipal/identity_provider.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class AppPrincipalIdentityProvider(BaseEntity): +class AppPrincipalIdentityProvider(Entity): """Represents an identity provider for app principals.""" @staticmethod diff --git a/office365/sharepoint/appprincipal/manager.py b/office365/sharepoint/appprincipal/manager.py index 81a32987d..38d4a1e44 100644 --- a/office365/sharepoint/appprincipal/manager.py +++ b/office365/sharepoint/appprincipal/manager.py @@ -1,5 +1,5 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class AppPrincipalManager(BaseEntity): +class AppPrincipalManager(Entity): """Represents a top level object used to manage app principals.""" diff --git a/office365/sharepoint/appprincipal/name.py b/office365/sharepoint/appprincipal/name.py index 895dedec4..9f2b2be37 100644 --- a/office365/sharepoint/appprincipal/name.py +++ b/office365/sharepoint/appprincipal/name.py @@ -1,5 +1,5 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class AppPrincipalName(BaseEntity): +class AppPrincipalName(Entity): """Represents the name of an app principal.""" diff --git a/office365/sharepoint/apps/app_collection.py b/office365/sharepoint/apps/app_collection.py index 541844851..19ac6a2b8 100644 --- a/office365/sharepoint/apps/app_collection.py +++ b/office365/sharepoint/apps/app_collection.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class AppCollection(BaseEntity): +class AppCollection(Entity): @property def entity_type_name(self): return "Microsoft.AppServices.AppCollection" diff --git a/office365/sharepoint/apps/license_manager.py b/office365/sharepoint/apps/license_manager.py index bd3bb0726..92295ee7c 100644 --- a/office365/sharepoint/apps/license_manager.py +++ b/office365/sharepoint/apps/license_manager.py @@ -1,10 +1,10 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery from office365.sharepoint.apps.license_collection import AppLicenseCollection -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SPAppLicenseManager(BaseEntity): +class SPAppLicenseManager(Entity): def check_license(self, product_id): """ :param str product_id: diff --git a/office365/sharepoint/apps/solution_exporter.py b/office365/sharepoint/apps/solution_exporter.py index 7051da2d5..b811e563c 100644 --- a/office365/sharepoint/apps/solution_exporter.py +++ b/office365/sharepoint/apps/solution_exporter.py @@ -1,5 +1,5 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SolutionExporter(BaseEntity): +class SolutionExporter(Entity): pass diff --git a/office365/sharepoint/apps/user_solution.py b/office365/sharepoint/apps/user_solution.py index 867d653c4..5b0c3d0da 100644 --- a/office365/sharepoint/apps/user_solution.py +++ b/office365/sharepoint/apps/user_solution.py @@ -1,5 +1,5 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class UserSolution(BaseEntity): +class UserSolution(Entity): pass diff --git a/office365/sharepoint/attachments/attachment.py b/office365/sharepoint/attachments/attachment.py index 35295e5d0..ddaa61cfc 100644 --- a/office365/sharepoint/attachments/attachment.py +++ b/office365/sharepoint/attachments/attachment.py @@ -1,10 +1,10 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.internal.queries.upload_file import create_upload_file_query from office365.sharepoint.types.resource_path import ResourcePath as SPResPath -class Attachment(BaseEntity): +class Attachment(Entity): """Represents an attachment file in a SharePoint List Item.""" def download(self, file_object, use_path=True): diff --git a/office365/sharepoint/attachments/collection.py b/office365/sharepoint/attachments/collection.py index ac6d8ce4e..8f843295e 100644 --- a/office365/sharepoint/attachments/collection.py +++ b/office365/sharepoint/attachments/collection.py @@ -4,10 +4,10 @@ from office365.sharepoint.attachments.creation_information import ( AttachmentCreationInformation, ) -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection -class AttachmentCollection(BaseEntityCollection): +class AttachmentCollection(EntityCollection): """Represents a collection of Attachment resources.""" def __init__(self, context, resource_path=None, parent=None): diff --git a/office365/sharepoint/audit/audit.py b/office365/sharepoint/audit/audit.py index 9d8c5c23b..dc621c22a 100644 --- a/office365/sharepoint/audit/audit.py +++ b/office365/sharepoint/audit/audit.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class Audit(BaseEntity): +class Audit(Entity): """ Enables auditing of how site collections, sites, lists, folders, and list items are accessed, changed, and used. """ diff --git a/office365/sharepoint/authpolicy/events/auth_event.py b/office365/sharepoint/authpolicy/events/auth_event.py index 5ed57a018..a117eed67 100644 --- a/office365/sharepoint/authpolicy/events/auth_event.py +++ b/office365/sharepoint/authpolicy/events/auth_event.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SPAuthEvent(BaseEntity): +class SPAuthEvent(Entity): @property def entity_type_name(self): return "Microsoft.SharePoint.AuthPolicy.Events.SPAuthEvent" diff --git a/office365/sharepoint/businessdata/app_bdc_catalog.py b/office365/sharepoint/businessdata/app_bdc_catalog.py index 4fb08b568..9f72c6b37 100644 --- a/office365/sharepoint/businessdata/app_bdc_catalog.py +++ b/office365/sharepoint/businessdata/app_bdc_catalog.py @@ -1,10 +1,10 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery from office365.runtime.types.collections import StringCollection -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class AppBdcCatalog(BaseEntity): +class AppBdcCatalog(Entity): """ Represents the Business Data Connectivity (BDC) MetadataCatalog for an application that contains external content types provisioned by the application. diff --git a/office365/sharepoint/businessdata/infrastructure/securestore/connection_settings.py b/office365/sharepoint/businessdata/infrastructure/securestore/connection_settings.py index 786dac8a7..62bb880f0 100644 --- a/office365/sharepoint/businessdata/infrastructure/securestore/connection_settings.py +++ b/office365/sharepoint/businessdata/infrastructure/securestore/connection_settings.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class ConnectionSettings(BaseEntity): +class ConnectionSettings(Entity): """""" @property diff --git a/office365/sharepoint/campaigns/campaigns.py b/office365/sharepoint/campaigns/campaigns.py index ec3383812..56d42bfef 100644 --- a/office365/sharepoint/campaigns/campaigns.py +++ b/office365/sharepoint/campaigns/campaigns.py @@ -1,9 +1,9 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class Campaigns(BaseEntity): +class Campaigns(Entity): @staticmethod def get_campaign(context, campaign_id): """ diff --git a/office365/sharepoint/changes/change.py b/office365/sharepoint/changes/change.py index 5b4edd4be..af92e7893 100644 --- a/office365/sharepoint/changes/change.py +++ b/office365/sharepoint/changes/change.py @@ -1,8 +1,8 @@ -from office365.sharepoint.base_entity import BaseEntity from office365.sharepoint.changes.token import ChangeToken +from office365.sharepoint.entity import Entity -class Change(BaseEntity): +class Change(Entity): """Base class for a change. installation.""" @property diff --git a/office365/sharepoint/changes/collection.py b/office365/sharepoint/changes/collection.py index 146072153..8e1543523 100644 --- a/office365/sharepoint/changes/collection.py +++ b/office365/sharepoint/changes/collection.py @@ -1,8 +1,8 @@ -from office365.sharepoint.base_entity_collection import BaseEntityCollection from office365.sharepoint.changes.change import Change +from office365.sharepoint.entity_collection import EntityCollection -class ChangeCollection(BaseEntityCollection): +class ChangeCollection(EntityCollection): """Represents a collection of Change objects""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/client_context.py b/office365/sharepoint/client_context.py index e033c9d62..974921a50 100644 --- a/office365/sharepoint/client_context.py +++ b/office365/sharepoint/client_context.py @@ -599,12 +599,12 @@ def home_site(self): @property def publications(self): - from office365.sharepoint.base_entity_collection import BaseEntityCollection from office365.sharepoint.contentcenter.machinelearning.publications.publication import ( SPMachineLearningPublication, ) + from office365.sharepoint.entity_collection import EntityCollection - return BaseEntityCollection( + return EntityCollection( self, SPMachineLearningPublication, ResourcePath("publications") ) diff --git a/office365/sharepoint/clientsidecomponent/component_context_info.py b/office365/sharepoint/clientsidecomponent/component_context_info.py index 464fde5ef..c4c50f0ea 100644 --- a/office365/sharepoint/clientsidecomponent/component_context_info.py +++ b/office365/sharepoint/clientsidecomponent/component_context_info.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class ComponentContextInfo(BaseEntity): +class ComponentContextInfo(Entity): """This class functions as a wrapper of the ContextInfo object. Reserved for internal use only.""" @property diff --git a/office365/sharepoint/clientsidecomponent/hostedapps/add_response.py b/office365/sharepoint/clientsidecomponent/hostedapps/add_response.py index b30a86aae..60d9d5e76 100644 --- a/office365/sharepoint/clientsidecomponent/hostedapps/add_response.py +++ b/office365/sharepoint/clientsidecomponent/hostedapps/add_response.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class HostedAppAddResponse(BaseEntity): +class HostedAppAddResponse(Entity): @property def entity_type_name(self): return "Microsoft.SharePoint.ClientSideComponent.HostedAppAddResponse" diff --git a/office365/sharepoint/clientsidecomponent/hostedapps/app.py b/office365/sharepoint/clientsidecomponent/hostedapps/app.py index f89652289..68afaadf3 100644 --- a/office365/sharepoint/clientsidecomponent/hostedapps/app.py +++ b/office365/sharepoint/clientsidecomponent/hostedapps/app.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class HostedApp(BaseEntity): +class HostedApp(Entity): @property def entity_type_name(self): return "Microsoft.SharePoint.ClientSideComponent.HostedApp" diff --git a/office365/sharepoint/clientsidecomponent/hostedapps/manager.py b/office365/sharepoint/clientsidecomponent/hostedapps/manager.py index 66173a5a0..8b404cacc 100644 --- a/office365/sharepoint/clientsidecomponent/hostedapps/manager.py +++ b/office365/sharepoint/clientsidecomponent/hostedapps/manager.py @@ -1,9 +1,9 @@ from office365.runtime.paths.service_operation import ServiceOperationPath -from office365.sharepoint.base_entity import BaseEntity from office365.sharepoint.clientsidecomponent.hostedapps.app import HostedApp +from office365.sharepoint.entity import Entity -class HostedAppsManager(BaseEntity): +class HostedAppsManager(Entity): def get_by_id(self, _id): """ Gets an hosted app based on the Id. diff --git a/office365/sharepoint/clientsidecomponent/storage_entity.py b/office365/sharepoint/clientsidecomponent/storage_entity.py index 94b843d91..42e25e6ca 100644 --- a/office365/sharepoint/clientsidecomponent/storage_entity.py +++ b/office365/sharepoint/clientsidecomponent/storage_entity.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class StorageEntity(BaseEntity): +class StorageEntity(Entity): """Storage entities which are available across app catalog scopes.""" @property diff --git a/office365/sharepoint/comments/collection.py b/office365/sharepoint/comments/collection.py index 51ccec6f5..c1c888805 100644 --- a/office365/sharepoint/comments/collection.py +++ b/office365/sharepoint/comments/collection.py @@ -1,10 +1,10 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity_collection import BaseEntityCollection from office365.sharepoint.comments.comment import Comment +from office365.sharepoint.entity_collection import EntityCollection -class CommentCollection(BaseEntityCollection): +class CommentCollection(EntityCollection): def __init__(self, context, resource_path=None): super(CommentCollection, self).__init__(context, Comment, resource_path) diff --git a/office365/sharepoint/comments/comment.py b/office365/sharepoint/comments/comment.py index a15064a37..ef5b97894 100644 --- a/office365/sharepoint/comments/comment.py +++ b/office365/sharepoint/comments/comment.py @@ -1,11 +1,11 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity import Entity +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.likes.user_entity import UserEntity -class Comment(BaseEntity): +class Comment(Entity): def like(self): """ The Like method makes the current user a liker of the comment. @@ -30,7 +30,7 @@ def liked_by(self): """ return self.properties.get( "likedBy", - BaseEntityCollection( + EntityCollection( self.context, UserEntity, ResourcePath("likedBy", self.resource_path) ), ) diff --git a/office365/sharepoint/compliance/store_proxy.py b/office365/sharepoint/compliance/store_proxy.py index 2b4783c05..653388215 100644 --- a/office365/sharepoint/compliance/store_proxy.py +++ b/office365/sharepoint/compliance/store_proxy.py @@ -2,11 +2,11 @@ from office365.runtime.client_value_collection import ClientValueCollection from office365.runtime.queries.service_operation import ServiceOperationQuery from office365.runtime.types.collections import StringCollection -from office365.sharepoint.base_entity import BaseEntity from office365.sharepoint.compliance.tag import ComplianceTag +from office365.sharepoint.entity import Entity -class SPPolicyStoreProxy(BaseEntity): +class SPPolicyStoreProxy(Entity): @staticmethod def get_available_tags_for_site(context, site_url, return_type=None): """ diff --git a/office365/sharepoint/contentcenter/machinelearning/enabled.py b/office365/sharepoint/contentcenter/machinelearning/enabled.py index f66225a2f..e07dc0258 100644 --- a/office365/sharepoint/contentcenter/machinelearning/enabled.py +++ b/office365/sharepoint/contentcenter/machinelearning/enabled.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SPMachineLearningEnabled(BaseEntity): +class SPMachineLearningEnabled(Entity): @property def is_syntex_payg_enabled(self): """ diff --git a/office365/sharepoint/contentcenter/machinelearning/hub.py b/office365/sharepoint/contentcenter/machinelearning/hub.py index 467f5e259..3af4813cd 100644 --- a/office365/sharepoint/contentcenter/machinelearning/hub.py +++ b/office365/sharepoint/contentcenter/machinelearning/hub.py @@ -2,7 +2,6 @@ from office365.runtime.client_value_collection import ClientValueCollection from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity from office365.sharepoint.compliance.tag import ComplianceTag from office365.sharepoint.contentcenter.machinelearning.enabled import ( SPMachineLearningEnabled, @@ -16,9 +15,10 @@ from office365.sharepoint.contentcenter.syntex_models_landing_info import ( SyntexModelsLandingInfo, ) +from office365.sharepoint.entity import Entity -class SPMachineLearningHub(BaseEntity): +class SPMachineLearningHub(Entity): def get_by_content_type_id(self, content_type_id): """ :param str content_type_id: diff --git a/office365/sharepoint/contentcenter/machinelearning/models/collection.py b/office365/sharepoint/contentcenter/machinelearning/models/collection.py index 9f380ef5b..c9b2f8c03 100644 --- a/office365/sharepoint/contentcenter/machinelearning/models/collection.py +++ b/office365/sharepoint/contentcenter/machinelearning/models/collection.py @@ -1,11 +1,11 @@ from office365.runtime.paths.service_operation import ServiceOperationPath -from office365.sharepoint.base_entity_collection import BaseEntityCollection from office365.sharepoint.contentcenter.machinelearning.models.model import ( SPMachineLearningModel, ) +from office365.sharepoint.entity_collection import EntityCollection -class SPMachineLearningModelCollection(BaseEntityCollection): +class SPMachineLearningModelCollection(EntityCollection): def __init__(self, context, resource_path=None): super(SPMachineLearningModelCollection, self).__init__( context, SPMachineLearningModel, resource_path diff --git a/office365/sharepoint/contentcenter/machinelearning/models/entity_data.py b/office365/sharepoint/contentcenter/machinelearning/models/entity_data.py index e8f7a5542..dc1c19305 100644 --- a/office365/sharepoint/contentcenter/machinelearning/models/entity_data.py +++ b/office365/sharepoint/contentcenter/machinelearning/models/entity_data.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SPMachineLearningModelEntityData(BaseEntity): +class SPMachineLearningModelEntityData(Entity): @property def entity_type_name(self): return "Microsoft.Office.Server.ContentCenter.SPMachineLearningModelEntityData" diff --git a/office365/sharepoint/contentcenter/machinelearning/models/model.py b/office365/sharepoint/contentcenter/machinelearning/models/model.py index 8ae286a36..0431739a0 100644 --- a/office365/sharepoint/contentcenter/machinelearning/models/model.py +++ b/office365/sharepoint/contentcenter/machinelearning/models/model.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SPMachineLearningModel(BaseEntity): +class SPMachineLearningModel(Entity): """""" @property diff --git a/office365/sharepoint/contentcenter/machinelearning/publications/publication.py b/office365/sharepoint/contentcenter/machinelearning/publications/publication.py index 583d6c1ba..db48f66e1 100644 --- a/office365/sharepoint/contentcenter/machinelearning/publications/publication.py +++ b/office365/sharepoint/contentcenter/machinelearning/publications/publication.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SPMachineLearningPublication(BaseEntity): +class SPMachineLearningPublication(Entity): @property def entity_type_name(self): return "Microsoft.Office.Server.ContentCenter.SPMachineLearningPublication" diff --git a/office365/sharepoint/contentcenter/machinelearning/publications/result.py b/office365/sharepoint/contentcenter/machinelearning/publications/result.py index 5c52f7a9b..fd0e1f8f2 100644 --- a/office365/sharepoint/contentcenter/machinelearning/publications/result.py +++ b/office365/sharepoint/contentcenter/machinelearning/publications/result.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SPMachineLearningPublicationsResult(BaseEntity): +class SPMachineLearningPublicationsResult(Entity): """""" @property diff --git a/office365/sharepoint/contentcenter/machinelearning/samples/collection.py b/office365/sharepoint/contentcenter/machinelearning/samples/collection.py index 72c56f757..2c5995132 100644 --- a/office365/sharepoint/contentcenter/machinelearning/samples/collection.py +++ b/office365/sharepoint/contentcenter/machinelearning/samples/collection.py @@ -1,11 +1,11 @@ from office365.runtime.paths.service_operation import ServiceOperationPath -from office365.sharepoint.base_entity_collection import BaseEntityCollection from office365.sharepoint.contentcenter.machinelearning.samples.sample import ( SPMachineLearningSample, ) +from office365.sharepoint.entity_collection import EntityCollection -class SPMachineLearningSampleCollection(BaseEntityCollection): +class SPMachineLearningSampleCollection(EntityCollection): def __init__(self, context, resource_path=None): super(SPMachineLearningSampleCollection, self).__init__( context, SPMachineLearningSample, resource_path diff --git a/office365/sharepoint/contentcenter/machinelearning/samples/entity_data.py b/office365/sharepoint/contentcenter/machinelearning/samples/entity_data.py index 6184d8055..a649fdfe3 100644 --- a/office365/sharepoint/contentcenter/machinelearning/samples/entity_data.py +++ b/office365/sharepoint/contentcenter/machinelearning/samples/entity_data.py @@ -1,8 +1,8 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SPMachineLearningSampleEntityData(BaseEntity): +class SPMachineLearningSampleEntityData(Entity): def __init__(self, context): static_path = ResourcePath( "Microsoft.Office.Server.ContentCenter.SPMachineLearningSampleEntityData" diff --git a/office365/sharepoint/contentcenter/machinelearning/samples/sample.py b/office365/sharepoint/contentcenter/machinelearning/samples/sample.py index b691c8c25..f7d2d241a 100644 --- a/office365/sharepoint/contentcenter/machinelearning/samples/sample.py +++ b/office365/sharepoint/contentcenter/machinelearning/samples/sample.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SPMachineLearningSample(BaseEntity): +class SPMachineLearningSample(Entity): @property def entity_type_name(self): return "Microsoft.Office.Server.ContentCenter.SPMachineLearningSample" diff --git a/office365/sharepoint/contentcenter/machinelearning/workitems/collection.py b/office365/sharepoint/contentcenter/machinelearning/workitems/collection.py index 912dc5dba..96de2ab50 100644 --- a/office365/sharepoint/contentcenter/machinelearning/workitems/collection.py +++ b/office365/sharepoint/contentcenter/machinelearning/workitems/collection.py @@ -1,10 +1,10 @@ -from office365.sharepoint.base_entity_collection import BaseEntityCollection from office365.sharepoint.contentcenter.machinelearning.workitems.item import ( SPMachineLearningWorkItem, ) +from office365.sharepoint.entity_collection import EntityCollection -class SPMachineLearningWorkItemCollection(BaseEntityCollection): +class SPMachineLearningWorkItemCollection(EntityCollection): def __init__(self, context, resource_path=None): super(SPMachineLearningWorkItemCollection, self).__init__( context, SPMachineLearningWorkItem, resource_path diff --git a/office365/sharepoint/contentcenter/machinelearning/workitems/item.py b/office365/sharepoint/contentcenter/machinelearning/workitems/item.py index 103aedd5d..11650c1f3 100644 --- a/office365/sharepoint/contentcenter/machinelearning/workitems/item.py +++ b/office365/sharepoint/contentcenter/machinelearning/workitems/item.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SPMachineLearningWorkItem(BaseEntity): +class SPMachineLearningWorkItem(Entity): @property def entity_type_name(self): return "Microsoft.Office.Server.ContentCenter.SPMachineLearningWorkItem" diff --git a/office365/sharepoint/contentcenter/syntex_models_landing_info.py b/office365/sharepoint/contentcenter/syntex_models_landing_info.py index b5c394417..ff5590eef 100644 --- a/office365/sharepoint/contentcenter/syntex_models_landing_info.py +++ b/office365/sharepoint/contentcenter/syntex_models_landing_info.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SyntexModelsLandingInfo(BaseEntity): +class SyntexModelsLandingInfo(Entity): @property def entity_type_name(self): return "Microsoft.Office.Server.ContentCenter.SyntexModelsLandingInfo" diff --git a/office365/sharepoint/contenttypes/collection.py b/office365/sharepoint/contenttypes/collection.py index 4fc6ebbf2..78551d775 100644 --- a/office365/sharepoint/contenttypes/collection.py +++ b/office365/sharepoint/contenttypes/collection.py @@ -1,12 +1,12 @@ from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.create_entity import CreateEntityQuery from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity_collection import BaseEntityCollection from office365.sharepoint.contenttypes.content_type import ContentType from office365.sharepoint.contenttypes.entity_data import ContentTypeEntityData +from office365.sharepoint.entity_collection import EntityCollection -class ContentTypeCollection(BaseEntityCollection): +class ContentTypeCollection(EntityCollection): """Content Type resource collection""" def __init__(self, context, resource_path=None, parent=None): diff --git a/office365/sharepoint/contenttypes/content_type.py b/office365/sharepoint/contenttypes/content_type.py index 12721a8da..8409a9cf1 100644 --- a/office365/sharepoint/contenttypes/content_type.py +++ b/office365/sharepoint/contenttypes/content_type.py @@ -1,14 +1,14 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery from office365.runtime.types.collections import StringCollection -from office365.sharepoint.base_entity import BaseEntity from office365.sharepoint.contenttypes.content_type_id import ContentTypeId from office365.sharepoint.contenttypes.fieldlinks.collection import FieldLinkCollection +from office365.sharepoint.entity import Entity from office365.sharepoint.fields.collection import FieldCollection from office365.sharepoint.translation.user_resource import UserResource -class ContentType(BaseEntity): +class ContentType(Entity): """ Specifies a content type. diff --git a/office365/sharepoint/contenttypes/fieldlinks/collection.py b/office365/sharepoint/contenttypes/fieldlinks/collection.py index 047c064c0..3831e88e9 100644 --- a/office365/sharepoint/contenttypes/fieldlinks/collection.py +++ b/office365/sharepoint/contenttypes/fieldlinks/collection.py @@ -2,12 +2,12 @@ from office365.runtime.queries.create_entity import CreateEntityQuery from office365.runtime.queries.service_operation import ServiceOperationQuery from office365.runtime.types.collections import StringCollection -from office365.sharepoint.base_entity_collection import BaseEntityCollection from office365.sharepoint.contenttypes.fieldlinks.field_link import FieldLink +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.fields.field import Field -class FieldLinkCollection(BaseEntityCollection): +class FieldLinkCollection(EntityCollection): """Specifies a Collection for field links.""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/contenttypes/fieldlinks/field_link.py b/office365/sharepoint/contenttypes/fieldlinks/field_link.py index 0204c50e0..c199ae408 100644 --- a/office365/sharepoint/contenttypes/fieldlinks/field_link.py +++ b/office365/sharepoint/contenttypes/fieldlinks/field_link.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class FieldLink(BaseEntity): +class FieldLink(Entity): """Specifies a reference to a field or field definition for a content type.""" @property diff --git a/office365/sharepoint/convergence/consumer_permissions.py b/office365/sharepoint/convergence/consumer_permissions.py index 53179843b..37fc97cae 100644 --- a/office365/sharepoint/convergence/consumer_permissions.py +++ b/office365/sharepoint/convergence/consumer_permissions.py @@ -1,8 +1,8 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class ConsumerPermissions(BaseEntity): +class ConsumerPermissions(Entity): def __init__(self, context, path=None): if path is None: path = ResourcePath("Microsoft.SharePoint.Convergence.ConsumerPermissions") diff --git a/office365/sharepoint/customactions/action.py b/office365/sharepoint/customactions/action.py index c42d90dc0..16fa66f1a 100644 --- a/office365/sharepoint/customactions/action.py +++ b/office365/sharepoint/customactions/action.py @@ -1,10 +1,10 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.permissions.base_permissions import BasePermissions from office365.sharepoint.translation.user_resource import UserResource -class UserCustomAction(BaseEntity): +class UserCustomAction(Entity): """Specifies a custom action.""" def get_property(self, name, default_value=None): diff --git a/office365/sharepoint/directory/group.py b/office365/sharepoint/directory/group.py index 30d054ac7..2aebc87c2 100644 --- a/office365/sharepoint/directory/group.py +++ b/office365/sharepoint/directory/group.py @@ -1,10 +1,10 @@ -from office365.sharepoint.base_entity import BaseEntity -from office365.sharepoint.base_entity_collection import BaseEntityCollection from office365.sharepoint.directory.helper import SPHelper from office365.sharepoint.directory.members_info import MembersInfo +from office365.sharepoint.entity import Entity +from office365.sharepoint.entity_collection import EntityCollection -class Group(BaseEntity): +class Group(Entity): def get_members_info(self, row_limit): """""" result = MembersInfo(self.context) @@ -23,7 +23,7 @@ def get_members(self): """""" from office365.directory.users.user import User - members = BaseEntityCollection(self.context, User) + members = EntityCollection(self.context, User) def _group_loaded(): SPHelper.get_members(self.context, self.properties["Id"], members) @@ -35,7 +35,7 @@ def get_owners(self): """""" from office365.directory.users.user import User - owners = BaseEntityCollection(self.context, User) + owners = EntityCollection(self.context, User) def _group_loaded(): SPHelper.get_owners(self.context, self.properties["Id"], owners) diff --git a/office365/sharepoint/directory/group_and_user_status.py b/office365/sharepoint/directory/group_and_user_status.py index 294218209..262d4213b 100644 --- a/office365/sharepoint/directory/group_and_user_status.py +++ b/office365/sharepoint/directory/group_and_user_status.py @@ -1,9 +1,9 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity from office365.sharepoint.directory.group import Group +from office365.sharepoint.entity import Entity -class GroupAndUserStatus(BaseEntity): +class GroupAndUserStatus(Entity): @property def group(self): """Get a Group""" diff --git a/office365/sharepoint/directory/helper.py b/office365/sharepoint/directory/helper.py index 91e56da5d..f809e9f82 100644 --- a/office365/sharepoint/directory/helper.py +++ b/office365/sharepoint/directory/helper.py @@ -1,15 +1,15 @@ from office365.runtime.client_result import ClientResult from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity -from office365.sharepoint.base_entity_collection import BaseEntityCollection from office365.sharepoint.directory.members_info import MembersInfo from office365.sharepoint.directory.membership_result import MembershipResult from office365.sharepoint.directory.my_groups_result import MyGroupsResult from office365.sharepoint.directory.user import User +from office365.sharepoint.entity import Entity +from office365.sharepoint.entity_collection import EntityCollection -class SPHelper(BaseEntity): +class SPHelper(Entity): def __init__(self, context): super(SPHelper, self).__init__(context, ResourcePath("SP.Directory.SPHelper")) @@ -106,10 +106,10 @@ def get_members(context, group_id, return_type=None): """ :param str group_id: Group identifier :param office365.sharepoint.client_context.ClientContext context: SharePoint context - :param BaseEntityCollection or None return_type: Returns members + :param EntityCollection or None return_type: Returns members """ if return_type is None: - return_type = BaseEntityCollection(context, User) + return_type = EntityCollection(context, User) qry = ServiceOperationQuery( SPHelper(context), "GetMembers", [group_id], None, None, return_type ) @@ -122,10 +122,10 @@ def get_owners(context, group_id, return_type=None): """ :param str group_id: Group identifier :param office365.sharepoint.client_context.ClientContext context: SharePoint context - :param BaseEntityCollection or None return_type: Returns members + :param EntityCollection or None return_type: Returns members """ if return_type is None: - return_type = BaseEntityCollection(context, User) + return_type = EntityCollection(context, User) qry = ServiceOperationQuery( SPHelper(context), "GetOwners", [group_id], None, None, return_type ) diff --git a/office365/sharepoint/directory/link.py b/office365/sharepoint/directory/link.py index 6cc05c8ee..90f047e47 100644 --- a/office365/sharepoint/directory/link.py +++ b/office365/sharepoint/directory/link.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class Link(BaseEntity): +class Link(Entity): @property def entity_type_name(self): return "SP.Directory.Link" diff --git a/office365/sharepoint/directory/members_info.py b/office365/sharepoint/directory/members_info.py index bc14970f3..dce562c11 100644 --- a/office365/sharepoint/directory/members_info.py +++ b/office365/sharepoint/directory/members_info.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class MembersInfo(BaseEntity): +class MembersInfo(Entity): @property def entity_type_name(self): return "SP.Directory.MembersInfo" diff --git a/office365/sharepoint/directory/membership_result.py b/office365/sharepoint/directory/membership_result.py index ebcfe95f3..50bfc9a54 100644 --- a/office365/sharepoint/directory/membership_result.py +++ b/office365/sharepoint/directory/membership_result.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class MembershipResult(BaseEntity): +class MembershipResult(Entity): @property def entity_type_name(self): return "SP.Directory.MembershipResult" diff --git a/office365/sharepoint/directory/my_groups_result.py b/office365/sharepoint/directory/my_groups_result.py index 9fe42c39e..d28ef8465 100644 --- a/office365/sharepoint/directory/my_groups_result.py +++ b/office365/sharepoint/directory/my_groups_result.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class MyGroupsResult(BaseEntity): +class MyGroupsResult(Entity): @property def entity_type_name(self): return "SP.Directory.MyGroupsResult" diff --git a/office365/sharepoint/directory/provider/provider.py b/office365/sharepoint/directory/provider/provider.py index 55104f160..b67c58af2 100644 --- a/office365/sharepoint/directory/provider/provider.py +++ b/office365/sharepoint/directory/provider/provider.py @@ -1,8 +1,8 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SharePointDirectoryProvider(BaseEntity): +class SharePointDirectoryProvider(Entity): def __init__(self, context, resource_path=None): if resource_path is None: resource_path = ResourcePath( diff --git a/office365/sharepoint/directory/session.py b/office365/sharepoint/directory/session.py index 2853ed010..85ec79579 100644 --- a/office365/sharepoint/directory/session.py +++ b/office365/sharepoint/directory/session.py @@ -1,10 +1,10 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity from office365.sharepoint.directory.user import User +from office365.sharepoint.entity import Entity -class DirectorySession(BaseEntity): +class DirectorySession(Entity): def __init__(self, context): super(DirectorySession, self).__init__( context, ResourcePath("SP.Directory.DirectorySession") diff --git a/office365/sharepoint/directory/user.py b/office365/sharepoint/directory/user.py index 1d2b8a28f..b541e1c7c 100644 --- a/office365/sharepoint/directory/user.py +++ b/office365/sharepoint/directory/user.py @@ -1,9 +1,9 @@ from office365.runtime.client_result import ClientResult -from office365.sharepoint.base_entity import BaseEntity from office365.sharepoint.directory.my_groups_result import MyGroupsResult +from office365.sharepoint.entity import Entity -class User(BaseEntity): +class User(Entity): def is_member_of(self, group_id): return_type = ClientResult(self.context) diff --git a/office365/sharepoint/documentmanagement/document_id.py b/office365/sharepoint/documentmanagement/document_id.py index 9471ffe12..c939890bf 100644 --- a/office365/sharepoint/documentmanagement/document_id.py +++ b/office365/sharepoint/documentmanagement/document_id.py @@ -1,9 +1,9 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class DocumentId(BaseEntity): +class DocumentId(Entity): """ Contains methods that enable or disable the capability to assign Document IDs to query Document ID feature and assignment status, and to query and set Document ID providers. diff --git a/office365/sharepoint/base_entity.py b/office365/sharepoint/entity.py similarity index 97% rename from office365/sharepoint/base_entity.py rename to office365/sharepoint/entity.py index f08e9719b..3a846305f 100644 --- a/office365/sharepoint/base_entity.py +++ b/office365/sharepoint/entity.py @@ -3,7 +3,7 @@ from office365.runtime.queries.update_entity import UpdateEntityQuery -class BaseEntity(ClientObject): +class Entity(ClientObject): """SharePoint specific entity""" def with_credentials(self, credentials): diff --git a/office365/sharepoint/base_entity_collection.py b/office365/sharepoint/entity_collection.py similarity index 85% rename from office365/sharepoint/base_entity_collection.py rename to office365/sharepoint/entity_collection.py index fe99206bb..4f904baad 100644 --- a/office365/sharepoint/base_entity_collection.py +++ b/office365/sharepoint/entity_collection.py @@ -5,7 +5,7 @@ T = TypeVar("T") -class BaseEntityCollection(ClientObjectCollection[T]): +class EntityCollection(ClientObjectCollection[T]): """ SharePoint entity set """ diff --git a/office365/sharepoint/eventreceivers/definition.py b/office365/sharepoint/eventreceivers/definition.py index 0ecdb5267..b48d604bd 100644 --- a/office365/sharepoint/eventreceivers/definition.py +++ b/office365/sharepoint/eventreceivers/definition.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class EventReceiverDefinition(BaseEntity): +class EventReceiverDefinition(Entity): """Abstract base class that defines general properties of an event receiver for list items, lists, websites, and workflows.""" diff --git a/office365/sharepoint/eventreceivers/definition_collection.py b/office365/sharepoint/eventreceivers/definition_collection.py index 2a1db7339..5177fcfcd 100644 --- a/office365/sharepoint/eventreceivers/definition_collection.py +++ b/office365/sharepoint/eventreceivers/definition_collection.py @@ -1,9 +1,9 @@ from office365.runtime.paths.service_operation import ServiceOperationPath -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.eventreceivers.definition import EventReceiverDefinition -class EventReceiverDefinitionCollection(BaseEntityCollection): +class EventReceiverDefinitionCollection(EntityCollection): """ Represents a collection of SP.EventReceiverDefinition objects that are used to enumerate the list of registered event receivers for Windows SharePoint Services objects that can have events. diff --git a/office365/sharepoint/features/collection.py b/office365/sharepoint/features/collection.py index 3f0aac59a..7ac065b82 100644 --- a/office365/sharepoint/features/collection.py +++ b/office365/sharepoint/features/collection.py @@ -1,10 +1,10 @@ from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.features.feature import Feature -class FeatureCollection(BaseEntityCollection): +class FeatureCollection(EntityCollection): """Represents a collection of Feature resources.""" def __init__(self, context, resource_path=None, parent=None): diff --git a/office365/sharepoint/features/definitions/collection.py b/office365/sharepoint/features/definitions/collection.py index 872c79e09..1cee80822 100644 --- a/office365/sharepoint/features/definitions/collection.py +++ b/office365/sharepoint/features/definitions/collection.py @@ -1,9 +1,9 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.features.definitions.definition import FeatureDefinition -class FeatureDefinitionCollection(BaseEntityCollection): +class FeatureDefinitionCollection(EntityCollection): """Represents a collection of feature's definitions""" def __init__(self, context, resource_path=None, parent=None): diff --git a/office365/sharepoint/features/definitions/definition.py b/office365/sharepoint/features/definitions/definition.py index a9a615d49..39ea623c8 100644 --- a/office365/sharepoint/features/definitions/definition.py +++ b/office365/sharepoint/features/definitions/definition.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class FeatureDefinition(BaseEntity): +class FeatureDefinition(Entity): """Contains the base definition of a feature, including its name, ID, scope, and version.""" @property diff --git a/office365/sharepoint/features/feature.py b/office365/sharepoint/features/feature.py index a902b6ce9..88bbbcca0 100644 --- a/office365/sharepoint/features/feature.py +++ b/office365/sharepoint/features/feature.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class Feature(BaseEntity): +class Feature(Entity): """Represents an activated feature.""" @property diff --git a/office365/sharepoint/fields/collection.py b/office365/sharepoint/fields/collection.py index 56fb4871b..1cff872fd 100644 --- a/office365/sharepoint/fields/collection.py +++ b/office365/sharepoint/fields/collection.py @@ -1,7 +1,7 @@ from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.create_entity import CreateEntityQuery from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.fields.creation_information import FieldCreationInformation from office365.sharepoint.fields.field import Field from office365.sharepoint.fields.type import FieldType @@ -12,7 +12,7 @@ from office365.sharepoint.taxonomy.sets.set import TermSet -class FieldCollection(BaseEntityCollection): +class FieldCollection(EntityCollection[Field]): """Represents a collection of Field resource.""" def __init__(self, context, resource_path=None, parent=None): diff --git a/office365/sharepoint/fields/field.py b/office365/sharepoint/fields/field.py index a7e1b5292..f557ec45a 100644 --- a/office365/sharepoint/fields/field.py +++ b/office365/sharepoint/fields/field.py @@ -1,12 +1,12 @@ from office365.runtime.client_result import ClientResult from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.fields.type import FieldType from office365.sharepoint.translation.user_resource import UserResource -class Field(BaseEntity): +class Field(Entity): """A container for metadata within a SharePoint list and associated list items.""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/fields/related_field.py b/office365/sharepoint/fields/related_field.py index 24184dcdd..d3cd62fd8 100644 --- a/office365/sharepoint/fields/related_field.py +++ b/office365/sharepoint/fields/related_field.py @@ -1,8 +1,8 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class RelatedField(BaseEntity): +class RelatedField(Entity): """Represents a Lookup Field that points to a given list on a Web site.""" @property diff --git a/office365/sharepoint/fields/related_field_collection.py b/office365/sharepoint/fields/related_field_collection.py index e76461e17..ea3106745 100644 --- a/office365/sharepoint/fields/related_field_collection.py +++ b/office365/sharepoint/fields/related_field_collection.py @@ -1,9 +1,9 @@ from office365.runtime.paths.service_operation import ServiceOperationPath -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.fields.related_field import RelatedField -class RelatedFieldCollection(BaseEntityCollection): +class RelatedFieldCollection(EntityCollection): """Represents a collection of RelatedField resources.""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/fields/string_values.py b/office365/sharepoint/fields/string_values.py index 43f7f622d..40757b2eb 100644 --- a/office365/sharepoint/fields/string_values.py +++ b/office365/sharepoint/fields/string_values.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class FieldStringValues(BaseEntity): +class FieldStringValues(Entity): """ Specifies a collection that contains key value pairs. The FieldStringValues type contains CSOM expando fields. The value type for the CSOM expando fields MUST be CSOM String. diff --git a/office365/sharepoint/files/checked_out_file.py b/office365/sharepoint/files/checked_out_file.py index 812778975..9e1c1be65 100644 --- a/office365/sharepoint/files/checked_out_file.py +++ b/office365/sharepoint/files/checked_out_file.py @@ -1,11 +1,11 @@ from office365.runtime.paths.key import KeyPath from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.principal.users.user import User -class CheckedOutFile(BaseEntity): +class CheckedOutFile(Entity): """Represents a checked-out file in a document library or workspace.""" def takeover_checkout(self): diff --git a/office365/sharepoint/files/checked_out_file_collection.py b/office365/sharepoint/files/checked_out_file_collection.py index 4458a19fd..4439fd0f5 100644 --- a/office365/sharepoint/files/checked_out_file_collection.py +++ b/office365/sharepoint/files/checked_out_file_collection.py @@ -1,9 +1,9 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.files.checked_out_file import CheckedOutFile -class CheckedOutFileCollection(BaseEntityCollection): +class CheckedOutFileCollection(EntityCollection): def __init__(self, context, resource_path=None): super(CheckedOutFileCollection, self).__init__( context, CheckedOutFile, resource_path diff --git a/office365/sharepoint/files/collection.py b/office365/sharepoint/files/collection.py index 7533c1e26..115e3db1e 100644 --- a/office365/sharepoint/files/collection.py +++ b/office365/sharepoint/files/collection.py @@ -2,7 +2,7 @@ from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.files.creation_information import FileCreationInformation from office365.sharepoint.files.file import File from office365.sharepoint.internal.queries.upload_session import ( @@ -11,7 +11,7 @@ from office365.sharepoint.types.resource_path import ResourcePath as SPResPath -class FileCollection(BaseEntityCollection): +class FileCollection(EntityCollection): """Represents a collection of File resources.""" def __init__(self, context, resource_path=None, parent=None): diff --git a/office365/sharepoint/files/file.py b/office365/sharepoint/files/file.py index 8dce4d7a5..a329e7042 100644 --- a/office365/sharepoint/files/file.py +++ b/office365/sharepoint/files/file.py @@ -10,8 +10,8 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery from office365.runtime.queries.update_entity import UpdateEntityQuery from office365.sharepoint.activities.capabilities import ActivityCapabilities -from office365.sharepoint.base_entity import BaseEntity -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity import Entity +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.files.versions.collection import FileVersionCollection from office365.sharepoint.files.versions.event import FileVersionEvent from office365.sharepoint.folders.folder import Folder @@ -35,7 +35,7 @@ from office365.sharepoint.webparts.personalization_scope import PersonalizationScope -class AbstractFile(BaseEntity): +class AbstractFile(Entity): def read(self): """Immediately read content of file""" if not self.is_property_available("ServerRelativeUrl"): @@ -704,7 +704,7 @@ def version_events(self): """Gets the history of events on this version object.""" return self.properties.get( "VersionEvents", - BaseEntityCollection( + EntityCollection( self.context, FileVersionEvent, ResourcePath("VersionEvents", self.resource_path), diff --git a/office365/sharepoint/files/recent_file_collection.py b/office365/sharepoint/files/recent_file_collection.py index 56910d0aa..3a97703a2 100644 --- a/office365/sharepoint/files/recent_file_collection.py +++ b/office365/sharepoint/files/recent_file_collection.py @@ -1,10 +1,10 @@ from office365.runtime.client_result import ClientResult from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class RecentFileCollection(BaseEntity): +class RecentFileCollection(Entity): def __init__(self, context): super(RecentFileCollection, self).__init__( context, ResourcePath("SP.RecentFileCollection") diff --git a/office365/sharepoint/files/versions/collection.py b/office365/sharepoint/files/versions/collection.py index d7cc09971..20c04fa9e 100644 --- a/office365/sharepoint/files/versions/collection.py +++ b/office365/sharepoint/files/versions/collection.py @@ -1,10 +1,10 @@ from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.files.versions.version import FileVersion -class FileVersionCollection(BaseEntityCollection): +class FileVersionCollection(EntityCollection): """Represents a collection of FileVersion.""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/files/versions/event.py b/office365/sharepoint/files/versions/event.py index 63074593e..c1e060db3 100644 --- a/office365/sharepoint/files/versions/event.py +++ b/office365/sharepoint/files/versions/event.py @@ -1,9 +1,9 @@ from office365.runtime.client_value_collection import ClientValueCollection -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.sharing.shared_with_user import SharedWithUser -class FileVersionEvent(BaseEntity): +class FileVersionEvent(Entity): """Represents an event object happened on a Microsoft.SharePoint.SPFile.""" @property diff --git a/office365/sharepoint/files/versions/version.py b/office365/sharepoint/files/versions/version.py index 65636fbab..2b94b87d4 100644 --- a/office365/sharepoint/files/versions/version.py +++ b/office365/sharepoint/files/versions/version.py @@ -3,10 +3,10 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class FileVersion(BaseEntity): +class FileVersion(Entity): """Represents a version of a File object.""" def download(self, file_object): diff --git a/office365/sharepoint/flows/synchronization_result.py b/office365/sharepoint/flows/synchronization_result.py index ac62b10f0..64785e619 100644 --- a/office365/sharepoint/flows/synchronization_result.py +++ b/office365/sharepoint/flows/synchronization_result.py @@ -1,5 +1,5 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class FlowSynchronizationResult(BaseEntity): +class FlowSynchronizationResult(Entity): pass diff --git a/office365/sharepoint/folders/collection.py b/office365/sharepoint/folders/collection.py index 008d972ca..7eea929ee 100644 --- a/office365/sharepoint/folders/collection.py +++ b/office365/sharepoint/folders/collection.py @@ -1,12 +1,12 @@ from office365.runtime.paths.key import KeyPath from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.folders.folder import Folder from office365.sharepoint.types.resource_path import ResourcePath as SPResPath -class FolderCollection(BaseEntityCollection): +class FolderCollection(EntityCollection): """Represents a collection of Folder resources.""" def __init__(self, context, resource_path=None, parent=None): diff --git a/office365/sharepoint/folders/coloring.py b/office365/sharepoint/folders/coloring.py index c22fc5f83..3c16f75ec 100644 --- a/office365/sharepoint/folders/coloring.py +++ b/office365/sharepoint/folders/coloring.py @@ -1,9 +1,9 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.folders.folder import Folder -class FolderColoring(BaseEntity): +class FolderColoring(Entity): """""" def create_folder( diff --git a/office365/sharepoint/folders/folder.py b/office365/sharepoint/folders/folder.py index 3c24c2bd5..5b16ec719 100644 --- a/office365/sharepoint/folders/folder.py +++ b/office365/sharepoint/folders/folder.py @@ -5,10 +5,10 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery from office365.runtime.queries.update_entity import UpdateEntityQuery -from office365.sharepoint.base_entity import BaseEntity from office365.sharepoint.changes.collection import ChangeCollection from office365.sharepoint.changes.query import ChangeQuery from office365.sharepoint.contenttypes.content_type_id import ContentTypeId +from office365.sharepoint.entity import Entity from office365.sharepoint.listitems.listitem import ListItem from office365.sharepoint.sharing.document_manager import DocumentSharingManager from office365.sharepoint.sharing.user_sharing_result import UserSharingResult @@ -18,7 +18,7 @@ from office365.sharepoint.utilities.move_copy_util import MoveCopyUtil -class Folder(BaseEntity): +class Folder(Entity): """Represents a folder in a SharePoint Web site.""" @staticmethod diff --git a/office365/sharepoint/forms/collection.py b/office365/sharepoint/forms/collection.py index 0d44a2bc7..ceebd3986 100644 --- a/office365/sharepoint/forms/collection.py +++ b/office365/sharepoint/forms/collection.py @@ -1,9 +1,9 @@ from office365.runtime.paths.service_operation import ServiceOperationPath -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.forms.form import Form -class FormCollection(BaseEntityCollection): +class FormCollection(EntityCollection): def __init__(self, context, resource_path=None): """Specifies a collection of list forms for a list.""" super(FormCollection, self).__init__(context, Form, resource_path) diff --git a/office365/sharepoint/forms/customization.py b/office365/sharepoint/forms/customization.py index 02d04c460..ccc98b8d7 100644 --- a/office365/sharepoint/forms/customization.py +++ b/office365/sharepoint/forms/customization.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class FormsCustomization(BaseEntity): +class FormsCustomization(Entity): @property def entity_type_name(self): return "SP.Internal.FormsCustomization" diff --git a/office365/sharepoint/forms/form.py b/office365/sharepoint/forms/form.py index c3e5da566..e5d70aaf3 100644 --- a/office365/sharepoint/forms/form.py +++ b/office365/sharepoint/forms/form.py @@ -1,8 +1,8 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.types.resource_path import ResourcePath as SPResPath -class Form(BaseEntity): +class Form(Entity): """A form provides a display and editing interface for a single list item.""" @property diff --git a/office365/sharepoint/largeoperation/operation.py b/office365/sharepoint/largeoperation/operation.py index cf34ba93f..99c5ab85b 100644 --- a/office365/sharepoint/largeoperation/operation.py +++ b/office365/sharepoint/largeoperation/operation.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SPLargeOperation(BaseEntity): +class SPLargeOperation(Entity): @property def entity_type_name(self): return "Microsoft.SharePoint.LargeOperation.SPLargeOperation" diff --git a/office365/sharepoint/likes/liked_by_information.py b/office365/sharepoint/likes/liked_by_information.py index 74abd36bf..9f2cad993 100644 --- a/office365/sharepoint/likes/liked_by_information.py +++ b/office365/sharepoint/likes/liked_by_information.py @@ -1,10 +1,10 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity import Entity +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.likes.user_entity import UserEntity -class LikedByInformation(BaseEntity): +class LikedByInformation(Entity): """Represents the information about the set of users who liked the list item.""" @property @@ -33,7 +33,7 @@ def liked_by(self): """ return self.properties.get( "likedBy", - BaseEntityCollection( + EntityCollection( self.context, UserEntity, ResourcePath("likedBy", self.resource_path) ), ) diff --git a/office365/sharepoint/likes/user_entity.py b/office365/sharepoint/likes/user_entity.py index 611428097..318f96b54 100644 --- a/office365/sharepoint/likes/user_entity.py +++ b/office365/sharepoint/likes/user_entity.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class UserEntity(BaseEntity): +class UserEntity(Entity): """Represents a single like within a likedBy set of the list item.""" @property diff --git a/office365/sharepoint/listhome/favorite_lists.py b/office365/sharepoint/listhome/favorite_lists.py index f1caf8ec6..4c34b49c7 100644 --- a/office365/sharepoint/listhome/favorite_lists.py +++ b/office365/sharepoint/listhome/favorite_lists.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class FavoriteLists(BaseEntity): +class FavoriteLists(Entity): @property def entity_type_name(self): return "SP.FavoriteLists" diff --git a/office365/sharepoint/listitems/collection.py b/office365/sharepoint/listitems/collection.py index 5ece29910..167f47d17 100644 --- a/office365/sharepoint/listitems/collection.py +++ b/office365/sharepoint/listitems/collection.py @@ -1,9 +1,9 @@ from office365.runtime.paths.service_operation import ServiceOperationPath -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.listitems.listitem import ListItem -class ListItemCollection(BaseEntityCollection[ListItem]): +class ListItemCollection(EntityCollection[ListItem]): """List Item collection""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/listitems/listitem.py b/office365/sharepoint/listitems/listitem.py index 30bce3abe..b420e0c28 100644 --- a/office365/sharepoint/listitems/listitem.py +++ b/office365/sharepoint/listitems/listitem.py @@ -6,10 +6,10 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity_collection import BaseEntityCollection from office365.sharepoint.changes.collection import ChangeCollection from office365.sharepoint.changes.query import ChangeQuery from office365.sharepoint.comments.collection import CommentCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.fields.image_value import ImageFieldValue from office365.sharepoint.fields.lookup_value import FieldLookupValue from office365.sharepoint.fields.multi_lookup_value import FieldMultiLookupValue diff --git a/office365/sharepoint/listitems/versions/collection.py b/office365/sharepoint/listitems/versions/collection.py index 749ab4682..abae58202 100644 --- a/office365/sharepoint/listitems/versions/collection.py +++ b/office365/sharepoint/listitems/versions/collection.py @@ -1,13 +1,13 @@ from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.listitems.versions.get_parameters import ( GetListItemVersionsParameters, ) from office365.sharepoint.listitems.versions.version import ListItemVersion -class ListItemVersionCollection(BaseEntityCollection): +class ListItemVersionCollection(EntityCollection): """Specifies a collection of versions of a list item.""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/listitems/versions/version.py b/office365/sharepoint/listitems/versions/version.py index 479a1316f..a5b12549e 100644 --- a/office365/sharepoint/listitems/versions/version.py +++ b/office365/sharepoint/listitems/versions/version.py @@ -2,10 +2,10 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.paths.service_operation import ServiceOperationPath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class ListItemVersion(BaseEntity): +class ListItemVersion(Entity): """Represents a version of a list item.""" @property diff --git a/office365/sharepoint/lists/bloom_filter.py b/office365/sharepoint/lists/bloom_filter.py index 051fac71b..edc3c40d3 100644 --- a/office365/sharepoint/lists/bloom_filter.py +++ b/office365/sharepoint/lists/bloom_filter.py @@ -1,8 +1,8 @@ from office365.runtime.client_value_collection import ClientValueCollection -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class ListBloomFilter(BaseEntity): +class ListBloomFilter(Entity): """Specifies a Bloom filter (probabilistic structure for checking the existence of list items).""" @property diff --git a/office365/sharepoint/lists/collection.py b/office365/sharepoint/lists/collection.py index 31b137480..590fc2f91 100644 --- a/office365/sharepoint/lists/collection.py +++ b/office365/sharepoint/lists/collection.py @@ -1,11 +1,11 @@ from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.create_entity import CreateEntityQuery from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.lists.list import List -class ListCollection(BaseEntityCollection): +class ListCollection(EntityCollection): """Specifies a collection of lists.""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/lists/creatables_info.py b/office365/sharepoint/lists/creatables_info.py index 697ddbbcf..1a2c24dbb 100644 --- a/office365/sharepoint/lists/creatables_info.py +++ b/office365/sharepoint/lists/creatables_info.py @@ -1,8 +1,8 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.lists.creatable_item_info import CreatableItemInfoCollection -class CreatablesInfo(BaseEntity): +class CreatablesInfo(Entity): """ Returns an object that describes what this list can create, and a collection of links to visit in order to create those things. If it can't create certain things, it contains an error message describing why. diff --git a/office365/sharepoint/lists/currency.py b/office365/sharepoint/lists/currency.py index 75dc892ca..e6c009725 100644 --- a/office365/sharepoint/lists/currency.py +++ b/office365/sharepoint/lists/currency.py @@ -1,12 +1,12 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.lists.currency_information_collection import ( CurrencyInformationCollection, ) -class CurrencyList(BaseEntity): +class CurrencyList(Entity): """List of supported currencies.""" @staticmethod diff --git a/office365/sharepoint/lists/template.py b/office365/sharepoint/lists/template.py index 4b8a18559..48d16c6af 100644 --- a/office365/sharepoint/lists/template.py +++ b/office365/sharepoint/lists/template.py @@ -1,10 +1,10 @@ from office365.runtime.client_result import ClientResult from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class ListTemplate(BaseEntity): +class ListTemplate(Entity): """ Represents a list definition or a list template, which defines the fields and views for a list. List definitions are contained in files within diff --git a/office365/sharepoint/lists/template_collection.py b/office365/sharepoint/lists/template_collection.py index fe74152f7..db45c3c1c 100644 --- a/office365/sharepoint/lists/template_collection.py +++ b/office365/sharepoint/lists/template_collection.py @@ -1,9 +1,9 @@ from office365.runtime.paths.service_operation import ServiceOperationPath -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.lists.template import ListTemplate -class ListTemplateCollection(BaseEntityCollection): +class ListTemplateCollection(EntityCollection): """Specifies a collection of list templates""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/logger/logFileInfo.py b/office365/sharepoint/logger/logFileInfo.py index f431eb4f0..f73a8550d 100644 --- a/office365/sharepoint/logger/logFileInfo.py +++ b/office365/sharepoint/logger/logFileInfo.py @@ -1,5 +1,5 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class LogFileInfo(BaseEntity): +class LogFileInfo(Entity): pass diff --git a/office365/sharepoint/logger/logFileInfoCollection.py b/office365/sharepoint/logger/logFileInfoCollection.py index 5c225f6af..8dbb377cc 100644 --- a/office365/sharepoint/logger/logFileInfoCollection.py +++ b/office365/sharepoint/logger/logFileInfoCollection.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.logger.logFileInfo import LogFileInfo -class LogFileInfoCollection(BaseEntityCollection): +class LogFileInfoCollection(EntityCollection): def __init__(self, context, resource_path=None): super(LogFileInfoCollection, self).__init__(context, LogFileInfo, resource_path) diff --git a/office365/sharepoint/logger/log_export.py b/office365/sharepoint/logger/log_export.py index 891ebfeb1..36644e335 100644 --- a/office365/sharepoint/logger/log_export.py +++ b/office365/sharepoint/logger/log_export.py @@ -1,11 +1,11 @@ from office365.runtime.client_result import ClientResult from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.logger.logFileInfoCollection import LogFileInfoCollection -class LogExport(BaseEntity): +class LogExport(Entity): def __init__(self, context): """This is the primary class that should be instantiated to obtain metadata about the logs that you can download.""" diff --git a/office365/sharepoint/marketplace/app_metadata.py b/office365/sharepoint/marketplace/app_metadata.py index a9f359845..bb8372f0a 100644 --- a/office365/sharepoint/marketplace/app_metadata.py +++ b/office365/sharepoint/marketplace/app_metadata.py @@ -1,8 +1,8 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class CorporateCatalogAppMetadata(BaseEntity): +class CorporateCatalogAppMetadata(Entity): """App metadata for apps stored in the corporate catalog.""" def deploy(self, skip_feature_deployment): diff --git a/office365/sharepoint/marketplace/app_metadata_collection.py b/office365/sharepoint/marketplace/app_metadata_collection.py index 2acd21334..a8007b1e8 100644 --- a/office365/sharepoint/marketplace/app_metadata_collection.py +++ b/office365/sharepoint/marketplace/app_metadata_collection.py @@ -1,9 +1,9 @@ from office365.runtime.paths.service_operation import ServiceOperationPath -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.marketplace.app_metadata import CorporateCatalogAppMetadata -class CorporateCatalogAppMetadataCollection(BaseEntityCollection): +class CorporateCatalogAppMetadataCollection(EntityCollection): """Collection of app metadata.""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/marketplace/corporatecuratedgallery/teams_package_download.py b/office365/sharepoint/marketplace/corporatecuratedgallery/teams_package_download.py index 3df742a22..e57b7ac93 100644 --- a/office365/sharepoint/marketplace/corporatecuratedgallery/teams_package_download.py +++ b/office365/sharepoint/marketplace/corporatecuratedgallery/teams_package_download.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class TeamsPackageDownload(BaseEntity): +class TeamsPackageDownload(Entity): """""" @property diff --git a/office365/sharepoint/marketplace/sitecollection/appcatalog/accessor.py b/office365/sharepoint/marketplace/sitecollection/appcatalog/accessor.py index 5047ab500..d0743e48d 100644 --- a/office365/sharepoint/marketplace/sitecollection/appcatalog/accessor.py +++ b/office365/sharepoint/marketplace/sitecollection/appcatalog/accessor.py @@ -1,11 +1,11 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.marketplace.app_metadata_collection import ( CorporateCatalogAppMetadataCollection, ) -class SiteCollectionCorporateCatalogAccessor(BaseEntity): +class SiteCollectionCorporateCatalogAccessor(Entity): """Accessor for the site collection corporate catalog.""" @property diff --git a/office365/sharepoint/marketplace/sitecollection/appcatalog/allowed_item.py b/office365/sharepoint/marketplace/sitecollection/appcatalog/allowed_item.py index 3f580fe48..64c7678fd 100644 --- a/office365/sharepoint/marketplace/sitecollection/appcatalog/allowed_item.py +++ b/office365/sharepoint/marketplace/sitecollection/appcatalog/allowed_item.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SiteCollectionAppCatalogAllowedItem(BaseEntity): +class SiteCollectionAppCatalogAllowedItem(Entity): """An entry in the site collection app catalog allow list.""" @property diff --git a/office365/sharepoint/marketplace/sitecollection/appcatalog/allowed_items.py b/office365/sharepoint/marketplace/sitecollection/appcatalog/allowed_items.py index 86a644648..4f87db988 100644 --- a/office365/sharepoint/marketplace/sitecollection/appcatalog/allowed_items.py +++ b/office365/sharepoint/marketplace/sitecollection/appcatalog/allowed_items.py @@ -1,10 +1,10 @@ -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.marketplace.sitecollection.appcatalog.allowed_item import ( SiteCollectionAppCatalogAllowedItem, ) -class SiteCollectionAppCatalogAllowedItems(BaseEntityCollection): +class SiteCollectionAppCatalogAllowedItems(EntityCollection): """An entry in the site collection app catalog allow list.""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/marketplace/tenant/appcatalog/accessor.py b/office365/sharepoint/marketplace/tenant/appcatalog/accessor.py index 5fdd6b1cf..9688321cb 100644 --- a/office365/sharepoint/marketplace/tenant/appcatalog/accessor.py +++ b/office365/sharepoint/marketplace/tenant/appcatalog/accessor.py @@ -2,7 +2,7 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.files.file import File from office365.sharepoint.marketplace.app_metadata import CorporateCatalogAppMetadata from office365.sharepoint.marketplace.app_metadata_collection import ( @@ -19,7 +19,7 @@ ) -class TenantCorporateCatalogAccessor(BaseEntity): +class TenantCorporateCatalogAccessor(Entity): """Accessor for the tenant corporate catalog.""" def add(self, content, overwrite, url): diff --git a/office365/sharepoint/microfeed/attachment_store.py b/office365/sharepoint/microfeed/attachment_store.py index 632044e38..3599c9de7 100644 --- a/office365/sharepoint/microfeed/attachment_store.py +++ b/office365/sharepoint/microfeed/attachment_store.py @@ -1,8 +1,8 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class MicrofeedAttachmentStore(BaseEntity): +class MicrofeedAttachmentStore(Entity): def __init__(self, context): super(MicrofeedAttachmentStore, self).__init__( context, ResourcePath("SP.Microfeed.MicrofeedAttachmentStore") diff --git a/office365/sharepoint/microfeed/data.py b/office365/sharepoint/microfeed/data.py index d9bdcbbfb..755dfb331 100644 --- a/office365/sharepoint/microfeed/data.py +++ b/office365/sharepoint/microfeed/data.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class MicrofeedData(BaseEntity): +class MicrofeedData(Entity): @property def entity_type_name(self): return "SP.Microfeed.MicrofeedData" diff --git a/office365/sharepoint/microfeed/manager.py b/office365/sharepoint/microfeed/manager.py index 5a1f4b0a9..e3a73ba8e 100644 --- a/office365/sharepoint/microfeed/manager.py +++ b/office365/sharepoint/microfeed/manager.py @@ -1,8 +1,8 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class MicrofeedManager(BaseEntity): +class MicrofeedManager(Entity): def __init__(self, context): super(MicrofeedManager, self).__init__( context, ResourcePath("SP.Microfeed.MicrofeedManager") diff --git a/office365/sharepoint/microservice/manager.py b/office365/sharepoint/microservice/manager.py index 429f25f6e..fc5cbb5b0 100644 --- a/office365/sharepoint/microservice/manager.py +++ b/office365/sharepoint/microservice/manager.py @@ -1,9 +1,9 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class MicroServiceManager(BaseEntity): +class MicroServiceManager(Entity): @staticmethod def add_microservice_work_item(context, payload, minutes, properties): """ diff --git a/office365/sharepoint/migration/job_status.py b/office365/sharepoint/migration/job_status.py index 393ad4f76..9f70a876d 100644 --- a/office365/sharepoint/migration/job_status.py +++ b/office365/sharepoint/migration/job_status.py @@ -1,5 +1,5 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SPMigrationJobStatus(BaseEntity): +class SPMigrationJobStatus(Entity): """""" diff --git a/office365/sharepoint/migrationcenter/common/task_entity_data.py b/office365/sharepoint/migrationcenter/common/task_entity_data.py index eb947df73..5edb2a7cf 100644 --- a/office365/sharepoint/migrationcenter/common/task_entity_data.py +++ b/office365/sharepoint/migrationcenter/common/task_entity_data.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class MigrationTaskEntityData(BaseEntity): +class MigrationTaskEntityData(Entity): @property def entity_type_name(self): return ( diff --git a/office365/sharepoint/migrationcenter/service/credential.py b/office365/sharepoint/migrationcenter/service/credential.py index 8d5a0ae89..79919236f 100644 --- a/office365/sharepoint/migrationcenter/service/credential.py +++ b/office365/sharepoint/migrationcenter/service/credential.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class MigrationCredential(BaseEntity): +class MigrationCredential(Entity): """""" @property diff --git a/office365/sharepoint/migrationcenter/service/properties.py b/office365/sharepoint/migrationcenter/service/properties.py index 0585c034f..0c835a5a5 100644 --- a/office365/sharepoint/migrationcenter/service/properties.py +++ b/office365/sharepoint/migrationcenter/service/properties.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class MigrationProperties(BaseEntity): +class MigrationProperties(Entity): """""" @property diff --git a/office365/sharepoint/migrationcenter/service/services.py b/office365/sharepoint/migrationcenter/service/services.py index 32fbce9da..24c20050a 100644 --- a/office365/sharepoint/migrationcenter/service/services.py +++ b/office365/sharepoint/migrationcenter/service/services.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class MigrationCenterServices(BaseEntity): +class MigrationCenterServices(Entity): @property def entity_type_name(self): return "Microsoft.Online.SharePoint.MigrationCenter.Service.MigrationCenterServices" diff --git a/office365/sharepoint/mount/folder_info.py b/office365/sharepoint/mount/folder_info.py index a87652e78..2b79cfc28 100644 --- a/office365/sharepoint/mount/folder_info.py +++ b/office365/sharepoint/mount/folder_info.py @@ -1,5 +1,5 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class MountedFolderInfo(BaseEntity): +class MountedFolderInfo(Entity): """""" diff --git a/office365/sharepoint/mount/point.py b/office365/sharepoint/mount/point.py index 63c4199b5..92b4adb39 100644 --- a/office365/sharepoint/mount/point.py +++ b/office365/sharepoint/mount/point.py @@ -1,9 +1,9 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.mount.folder_info import MountedFolderInfo -class MountPoint(BaseEntity): +class MountPoint(Entity): """""" @staticmethod diff --git a/office365/sharepoint/mount/service.py b/office365/sharepoint/mount/service.py index 115b047c9..db4757970 100644 --- a/office365/sharepoint/mount/service.py +++ b/office365/sharepoint/mount/service.py @@ -1,12 +1,12 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.mount.requests.get_remote_item_Info import ( GetRemoteItemInfoRequest, ) -class MountService(BaseEntity): +class MountService(Entity): @staticmethod def get_remote_item_info(context, remote_item_unique_ids): """ diff --git a/office365/sharepoint/multigeo/unified_group.py b/office365/sharepoint/multigeo/unified_group.py index a7de41a85..21046f9da 100644 --- a/office365/sharepoint/multigeo/unified_group.py +++ b/office365/sharepoint/multigeo/unified_group.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class UnifiedGroup(BaseEntity): +class UnifiedGroup(Entity): @property def entity_type_name(self): return "Microsoft.Online.SharePoint.MultiGeo.Service.UnifiedGroup" diff --git a/office365/sharepoint/navigation/home_site_navigation_settings.py b/office365/sharepoint/navigation/home_site_navigation_settings.py index eac39cfbd..3fcdb4b26 100644 --- a/office365/sharepoint/navigation/home_site_navigation_settings.py +++ b/office365/sharepoint/navigation/home_site_navigation_settings.py @@ -1,9 +1,9 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class HomeSiteNavigationSettings(BaseEntity): +class HomeSiteNavigationSettings(Entity): def __init__(self, context, resource_path=None): if resource_path is None: resource_path = ResourcePath( diff --git a/office365/sharepoint/navigation/metadata_settings.py b/office365/sharepoint/navigation/metadata_settings.py index 0436e60dd..863ed38c1 100644 --- a/office365/sharepoint/navigation/metadata_settings.py +++ b/office365/sharepoint/navigation/metadata_settings.py @@ -1,12 +1,12 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.navigation.configured_metadata_items import ( ConfiguredMetadataNavigationItemCollection, ) -class MetadataNavigationSettings(BaseEntity): +class MetadataNavigationSettings(Entity): """Described and allows changes to the meta-data navigation and filtering settings on an SPList.""" @staticmethod diff --git a/office365/sharepoint/navigation/navigation.py b/office365/sharepoint/navigation/navigation.py index 53e28d848..7b5771d8f 100644 --- a/office365/sharepoint/navigation/navigation.py +++ b/office365/sharepoint/navigation/navigation.py @@ -1,9 +1,9 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.navigation.node_collection import NavigationNodeCollection -class Navigation(BaseEntity): +class Navigation(Entity): """Represents navigation operations at the site collection level.""" @property diff --git a/office365/sharepoint/navigation/navigation_service.py b/office365/sharepoint/navigation/navigation_service.py index 60f427891..bd0c1fd55 100644 --- a/office365/sharepoint/navigation/navigation_service.py +++ b/office365/sharepoint/navigation/navigation_service.py @@ -1,7 +1,7 @@ from office365.runtime.client_result import ClientResult from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.navigation.home_site_navigation_settings import ( HomeSiteNavigationSettings, ) @@ -9,7 +9,7 @@ from office365.sharepoint.navigation.provider_type import NavigationProviderType -class NavigationService(BaseEntity): +class NavigationService(Entity): """The entry point for REST-based navigation service operations.""" def __init__(self, context): diff --git a/office365/sharepoint/navigation/node.py b/office365/sharepoint/navigation/node.py index 6d4c5a040..46ce1c634 100644 --- a/office365/sharepoint/navigation/node.py +++ b/office365/sharepoint/navigation/node.py @@ -1,9 +1,9 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.translation.user_resource import UserResource -class NavigationNode(BaseEntity): +class NavigationNode(Entity): """ Represents the URL to a specific navigation node and provides access to properties and methods for manipulating the ordering of the navigation node in a navigation node collection. diff --git a/office365/sharepoint/navigation/node_collection.py b/office365/sharepoint/navigation/node_collection.py index 396f61048..38332dae4 100644 --- a/office365/sharepoint/navigation/node_collection.py +++ b/office365/sharepoint/navigation/node_collection.py @@ -1,11 +1,11 @@ from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.create_entity import CreateEntityQuery from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.navigation.node import NavigationNode -class NavigationNodeCollection(BaseEntityCollection): +class NavigationNodeCollection(EntityCollection): def __init__(self, context, resource_path=None): super(NavigationNodeCollection, self).__init__( context, NavigationNode, resource_path diff --git a/office365/sharepoint/oauth/authentication.py b/office365/sharepoint/oauth/authentication.py index 4f55df4fc..1c9d9734a 100644 --- a/office365/sharepoint/oauth/authentication.py +++ b/office365/sharepoint/oauth/authentication.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class Authentication(BaseEntity): +class Authentication(Entity): """ Exposes relationships that represent the authentication methods. """ diff --git a/office365/sharepoint/oauth/native_client.py b/office365/sharepoint/oauth/native_client.py index ab3e5750e..6d86352fb 100644 --- a/office365/sharepoint/oauth/native_client.py +++ b/office365/sharepoint/oauth/native_client.py @@ -1,9 +1,9 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class NativeClient(BaseEntity): +class NativeClient(Entity): """Gets endpoints for native client authentication relative to current request.""" def __init__(self, context): diff --git a/office365/sharepoint/onboarding/job_entity_data.py b/office365/sharepoint/onboarding/job_entity_data.py index 71f690187..e3b979d25 100644 --- a/office365/sharepoint/onboarding/job_entity_data.py +++ b/office365/sharepoint/onboarding/job_entity_data.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class JobEntityData(BaseEntity): +class JobEntityData(Entity): """""" @property diff --git a/office365/sharepoint/orgnewssite/api.py b/office365/sharepoint/orgnewssite/api.py index dbbeaa9c1..0f7820585 100644 --- a/office365/sharepoint/orgnewssite/api.py +++ b/office365/sharepoint/orgnewssite/api.py @@ -1,11 +1,11 @@ from office365.runtime.client_result import ClientResult from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.orgnewssite.info import OrgNewsSiteInfo -class OrgNewsSiteApi(BaseEntity): +class OrgNewsSiteApi(Entity): def __init__(self, context, resource_path=None): if resource_path is None: resource_path = ResourcePath( diff --git a/office365/sharepoint/packaging/app_details.py b/office365/sharepoint/packaging/app_details.py index d6c81211d..cd0ff74e0 100644 --- a/office365/sharepoint/packaging/app_details.py +++ b/office365/sharepoint/packaging/app_details.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class AppDetails(BaseEntity): +class AppDetails(Entity): @property def entity_type_name(self): return "Microsoft.SharePoint.Packaging.AppDetails" diff --git a/office365/sharepoint/pageinstrumentation/click_manager.py b/office365/sharepoint/pageinstrumentation/click_manager.py index 5469eeb5f..15838c636 100644 --- a/office365/sharepoint/pageinstrumentation/click_manager.py +++ b/office365/sharepoint/pageinstrumentation/click_manager.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class ClickManager(BaseEntity): +class ClickManager(Entity): @property def entity_type_name(self): return "SP.PageInstrumentation.ClickManager" diff --git a/office365/sharepoint/permissions/irm/effective_settings.py b/office365/sharepoint/permissions/irm/effective_settings.py index 403d73697..d90b6d5fd 100644 --- a/office365/sharepoint/permissions/irm/effective_settings.py +++ b/office365/sharepoint/permissions/irm/effective_settings.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class EffectiveInformationRightsManagementSettings(BaseEntity): +class EffectiveInformationRightsManagementSettings(Entity): """A collection of effective IRM settings on the file.""" @property diff --git a/office365/sharepoint/permissions/irm/file_settings.py b/office365/sharepoint/permissions/irm/file_settings.py index ce063ed9f..c6f2ee3b9 100644 --- a/office365/sharepoint/permissions/irm/file_settings.py +++ b/office365/sharepoint/permissions/irm/file_settings.py @@ -1,8 +1,8 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class InformationRightsManagementFileSettings(BaseEntity): +class InformationRightsManagementFileSettings(Entity): """Represents the Information Rights Management (IRM) settings of a file.""" def reset(self): diff --git a/office365/sharepoint/permissions/irm/settings.py b/office365/sharepoint/permissions/irm/settings.py index 04ba1e056..e613a9921 100644 --- a/office365/sharepoint/permissions/irm/settings.py +++ b/office365/sharepoint/permissions/irm/settings.py @@ -1,9 +1,9 @@ import datetime -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class InformationRightsManagementSettings(BaseEntity): +class InformationRightsManagementSettings(Entity): """Represents the Information Rights Management (IRM) settings of a list in Microsoft SharePoint Foundation.""" @property diff --git a/office365/sharepoint/permissions/roles/assignments/assignment.py b/office365/sharepoint/permissions/roles/assignments/assignment.py index 9c24cc116..5183761b9 100644 --- a/office365/sharepoint/permissions/roles/assignments/assignment.py +++ b/office365/sharepoint/permissions/roles/assignments/assignment.py @@ -1,12 +1,12 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.permissions.roles.definitions.collection import ( RoleDefinitionCollection, ) from office365.sharepoint.principal.principal import Principal -class RoleAssignment(BaseEntity): +class RoleAssignment(Entity): """An association between a principal or a site group and a role definition.""" @property diff --git a/office365/sharepoint/permissions/roles/assignments/collection.py b/office365/sharepoint/permissions/roles/assignments/collection.py index a95b7ceb0..835ad8a5f 100644 --- a/office365/sharepoint/permissions/roles/assignments/collection.py +++ b/office365/sharepoint/permissions/roles/assignments/collection.py @@ -1,11 +1,11 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.permissions.roles.assignments.assignment import RoleAssignment -class RoleAssignmentCollection(BaseEntityCollection): +class RoleAssignmentCollection(EntityCollection): """Represents a collection of RoleAssignment resources.""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/permissions/roles/definitions/collection.py b/office365/sharepoint/permissions/roles/definitions/collection.py index 78c068282..f10bbcdea 100644 --- a/office365/sharepoint/permissions/roles/definitions/collection.py +++ b/office365/sharepoint/permissions/roles/definitions/collection.py @@ -1,14 +1,14 @@ from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.create_entity import CreateEntityQuery from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.permissions.roles.definitions.creation_information import ( RoleDefinitionCreationInformation, ) from office365.sharepoint.permissions.roles.definitions.definition import RoleDefinition -class RoleDefinitionCollection(BaseEntityCollection): +class RoleDefinitionCollection(EntityCollection): """Represents the collection of role definitions that are available within the site""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/permissions/roles/definitions/definition.py b/office365/sharepoint/permissions/roles/definitions/definition.py index 72123f795..3e2f9bef8 100644 --- a/office365/sharepoint/permissions/roles/definitions/definition.py +++ b/office365/sharepoint/permissions/roles/definitions/definition.py @@ -1,9 +1,9 @@ from office365.runtime.paths.service_operation import ServiceOperationPath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.permissions.base_permissions import BasePermissions -class RoleDefinition(BaseEntity): +class RoleDefinition(Entity): """Defines a single role definition, including a name, description, and set of rights.""" @property diff --git a/office365/sharepoint/permissions/securable_object.py b/office365/sharepoint/permissions/securable_object.py index daa4ffaf4..27d20b1b2 100644 --- a/office365/sharepoint/permissions/securable_object.py +++ b/office365/sharepoint/permissions/securable_object.py @@ -1,19 +1,16 @@ from office365.runtime.client_result import ClientResult -from office365.runtime.client_value_collection import ClientValueCollection from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.permissions.base_permissions import BasePermissions from office365.sharepoint.permissions.roles.assignments.assignment import RoleAssignment from office365.sharepoint.permissions.roles.assignments.collection import ( RoleAssignmentCollection, ) from office365.sharepoint.principal.users.user import User -from office365.sharepoint.sharing.document_manager import DocumentSharingManager -from office365.sharepoint.sharing.user_sharing_result import UserSharingResult -class SecurableObject(BaseEntity): +class SecurableObject(Entity): """An object that can be assigned security permissions.""" def get_role_assignment(self, principal): @@ -113,7 +110,9 @@ def get_user_effective_permissions(self, user): :param str or User user: Specifies the user login name or User object. """ - return_type = ClientResult(self.context, BasePermissions()) + return_type = ClientResult( + self.context, BasePermissions() + ) # type: ClientResult[BasePermissions] def _create_and_add_query(login_name): """ diff --git a/office365/sharepoint/permissions/utility.py b/office365/sharepoint/permissions/utility.py index f4ea35724..29f346b54 100644 --- a/office365/sharepoint/permissions/utility.py +++ b/office365/sharepoint/permissions/utility.py @@ -1,6 +1,6 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class Utility(BaseEntity): +class Utility(Entity): def __init__(self, context, resource_path): super(Utility, self).__init__(context, resource_path, "SP.Utilities") diff --git a/office365/sharepoint/photos/migration.py b/office365/sharepoint/photos/migration.py index df50d4e60..949bc6c6d 100644 --- a/office365/sharepoint/photos/migration.py +++ b/office365/sharepoint/photos/migration.py @@ -1,8 +1,8 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class PhotosMigration(BaseEntity): +class PhotosMigration(Entity): def __init__(self, context): static_path = ResourcePath("Microsoft.SharePoint.Photos.PhotosMigration") super(PhotosMigration, self).__init__(context, static_path) diff --git a/office365/sharepoint/policy/dlp_policy_tip.py b/office365/sharepoint/policy/dlp_policy_tip.py index 539acc7bf..7dc0eae20 100644 --- a/office365/sharepoint/policy/dlp_policy_tip.py +++ b/office365/sharepoint/policy/dlp_policy_tip.py @@ -1,8 +1,8 @@ from office365.runtime.types.collections import StringCollection -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class DlpPolicyTip(BaseEntity): +class DlpPolicyTip(Entity): """Provides information about the Data Loss Protection policy on an item so it can be shown to the user.""" @property diff --git a/office365/sharepoint/policy/evaluation_info.py b/office365/sharepoint/policy/evaluation_info.py index a8564be74..b9c21276c 100644 --- a/office365/sharepoint/policy/evaluation_info.py +++ b/office365/sharepoint/policy/evaluation_info.py @@ -1,5 +1,5 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class PolicyEvaluationInfo(BaseEntity): +class PolicyEvaluationInfo(Entity): pass diff --git a/office365/sharepoint/portal/collaboration_mailbox.py b/office365/sharepoint/portal/collaboration_mailbox.py index 8f23d32cd..037f41817 100644 --- a/office365/sharepoint/portal/collaboration_mailbox.py +++ b/office365/sharepoint/portal/collaboration_mailbox.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class CollaborationMailbox(BaseEntity): +class CollaborationMailbox(Entity): @property def entity_type_name(self): return "Microsoft.SharePoint.Portal.CollaborationMailbox" diff --git a/office365/sharepoint/portal/community_moderation.py b/office365/sharepoint/portal/community_moderation.py index 2a33e250d..b120a3708 100644 --- a/office365/sharepoint/portal/community_moderation.py +++ b/office365/sharepoint/portal/community_moderation.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class CommunityModeration(BaseEntity): +class CommunityModeration(Entity): @property def entity_type_name(self): return "Microsoft.SharePoint.Portal.CommunityModeration" diff --git a/office365/sharepoint/portal/groups/service.py b/office365/sharepoint/portal/groups/service.py index cf6699b27..e6ce63c5b 100644 --- a/office365/sharepoint/portal/groups/service.py +++ b/office365/sharepoint/portal/groups/service.py @@ -3,10 +3,10 @@ from office365.runtime.client_result import ClientResult from office365.runtime.http.http_method import HttpMethod from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class GroupService(BaseEntity): +class GroupService(Entity): def __init__(self, context, resource_path=None): super(GroupService, self).__init__(context, resource_path) diff --git a/office365/sharepoint/portal/home/service_context.py b/office365/sharepoint/portal/home/service_context.py index 2406cd5a9..5fbdffd95 100644 --- a/office365/sharepoint/portal/home/service_context.py +++ b/office365/sharepoint/portal/home/service_context.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SharePointHomeServiceContext(BaseEntity): +class SharePointHomeServiceContext(Entity): """ This data type is reserved for future use and MUST NOT be used by the protocol implementation. """ diff --git a/office365/sharepoint/portal/home/service_context_builder.py b/office365/sharepoint/portal/home/service_context_builder.py index 9d5d3fec1..a7cf76fef 100644 --- a/office365/sharepoint/portal/home/service_context_builder.py +++ b/office365/sharepoint/portal/home/service_context_builder.py @@ -1,11 +1,11 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.portal.home.service_context import ( SharePointHomeServiceContext, ) -class SharePointHomeServiceContextBuilder(BaseEntity): +class SharePointHomeServiceContextBuilder(Entity): def get_context(self): return_type = SharePointHomeServiceContext(self.context) qry = ServiceOperationQuery(self, "Context", None, None, None, return_type) diff --git a/office365/sharepoint/portal/hub_sites_utility.py b/office365/sharepoint/portal/hub_sites_utility.py index acdb1f640..2e5f49cb4 100644 --- a/office365/sharepoint/portal/hub_sites_utility.py +++ b/office365/sharepoint/portal/hub_sites_utility.py @@ -1,12 +1,12 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.tenant.administration.hubsites.collection import ( HubSiteCollection, ) -class SPHubSitesUtility(BaseEntity): +class SPHubSitesUtility(Entity): """You can use the class to register sites as hub sites, associate existing sites with hub sites, and obtain or update information about hub sites. """ diff --git a/office365/sharepoint/portal/linkedsites/manager.py b/office365/sharepoint/portal/linkedsites/manager.py index 4bb7b9447..ff4a4d390 100644 --- a/office365/sharepoint/portal/linkedsites/manager.py +++ b/office365/sharepoint/portal/linkedsites/manager.py @@ -1,12 +1,12 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.portal.linkedsites.list_contract import ( LinkedSitesListContract, ) -class SiteLinkingManager(BaseEntity): +class SiteLinkingManager(Entity): """""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/portal/mysite_recommendations.py b/office365/sharepoint/portal/mysite_recommendations.py index 2a32397c9..5c0fb9023 100644 --- a/office365/sharepoint/portal/mysite_recommendations.py +++ b/office365/sharepoint/portal/mysite_recommendations.py @@ -1,9 +1,9 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class MySiteRecommendations(BaseEntity): +class MySiteRecommendations(Entity): """Provides a method to get site and document recommendations for the current user, and methods to follow or stop following a particular item.""" diff --git a/office365/sharepoint/portal/organization_news.py b/office365/sharepoint/portal/organization_news.py index 0114fe1af..af118e625 100644 --- a/office365/sharepoint/portal/organization_news.py +++ b/office365/sharepoint/portal/organization_news.py @@ -2,14 +2,14 @@ from office365.runtime.client_value import ClientValue from office365.runtime.client_value_collection import ClientValueCollection from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity class OrganizationNewsSiteReference(ClientValue): pass -class OrganizationNews(BaseEntity): +class OrganizationNews(Entity): def sites_reference(self): return_type = ClientResult( self.context, ClientValueCollection(OrganizationNewsSiteReference) diff --git a/office365/sharepoint/portal/rating_settings.py b/office365/sharepoint/portal/rating_settings.py index bffc2d8f2..27e356073 100644 --- a/office365/sharepoint/portal/rating_settings.py +++ b/office365/sharepoint/portal/rating_settings.py @@ -1,9 +1,9 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class RatingSettings(BaseEntity): +class RatingSettings(Entity): @staticmethod def get_list_rating(context, list_id): """ diff --git a/office365/sharepoint/portal/sites/icon_manager.py b/office365/sharepoint/portal/sites/icon_manager.py index 25c377764..1c60a64c5 100644 --- a/office365/sharepoint/portal/sites/icon_manager.py +++ b/office365/sharepoint/portal/sites/icon_manager.py @@ -1,10 +1,10 @@ from office365.runtime.client_result import ClientResult from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SiteIconManager(BaseEntity): +class SiteIconManager(Entity): def __init__(self, context, resource_path=None): if resource_path is None: resource_path = ResourcePath("SiteIconManager") diff --git a/office365/sharepoint/portal/sites/manager.py b/office365/sharepoint/portal/sites/manager.py index fec6d1040..9dd996cdf 100644 --- a/office365/sharepoint/portal/sites/manager.py +++ b/office365/sharepoint/portal/sites/manager.py @@ -2,7 +2,7 @@ from office365.runtime.http.http_method import HttpMethod from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.portal.sites.creation_request import SPSiteCreationRequest from office365.sharepoint.portal.sites.creation_response import SPSiteCreationResponse from office365.sharepoint.teams.site_owner_response import ( @@ -11,7 +11,7 @@ from office365.sharepoint.viva.site_request_info import VivaSiteRequestInfo -class SPSiteManager(BaseEntity): +class SPSiteManager(Entity): """Provides REST methods for creating and managing SharePoint sites.""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/portal/suite_nav_data.py b/office365/sharepoint/portal/suite_nav_data.py index 7c4aaabbe..d6429c634 100644 --- a/office365/sharepoint/portal/suite_nav_data.py +++ b/office365/sharepoint/portal/suite_nav_data.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SuiteNavData(BaseEntity): +class SuiteNavData(Entity): @property def entity_type_name(self): return "Microsoft.SharePoint.Portal.SuiteNavData" diff --git a/office365/sharepoint/portal/theme_manager.py b/office365/sharepoint/portal/theme_manager.py index dd51f894c..8bc5db0a8 100644 --- a/office365/sharepoint/portal/theme_manager.py +++ b/office365/sharepoint/portal/theme_manager.py @@ -1,9 +1,9 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class ThemeManager(BaseEntity): +class ThemeManager(Entity): """SharePoint site theming REST interface to perform basic create, read, update, and delete (CRUD) operations on site themes.""" diff --git a/office365/sharepoint/portal/userprofiles/documents_shared_with_group.py b/office365/sharepoint/portal/userprofiles/documents_shared_with_group.py index 2df48a07c..2700d578f 100644 --- a/office365/sharepoint/portal/userprofiles/documents_shared_with_group.py +++ b/office365/sharepoint/portal/userprofiles/documents_shared_with_group.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class DocumentsSharedWithGroup(BaseEntity): +class DocumentsSharedWithGroup(Entity): """ Provides methods for working with a list that shares documents with a SharePoint Group on the user's personal site. """ diff --git a/office365/sharepoint/portal/userprofiles/documents_shared_with_me.py b/office365/sharepoint/portal/userprofiles/documents_shared_with_me.py index 174dea5a4..0bccad722 100644 --- a/office365/sharepoint/portal/userprofiles/documents_shared_with_me.py +++ b/office365/sharepoint/portal/userprofiles/documents_shared_with_me.py @@ -1,9 +1,9 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class DocumentsSharedWithMe(BaseEntity): +class DocumentsSharedWithMe(Entity): """Provides methods for working with a list that shares documents with the current user on the user's personal site. All methods in this object are static.""" diff --git a/office365/sharepoint/principal/groups/collection.py b/office365/sharepoint/principal/groups/collection.py index 40d430f8b..8e9393aa8 100644 --- a/office365/sharepoint/principal/groups/collection.py +++ b/office365/sharepoint/principal/groups/collection.py @@ -3,7 +3,7 @@ from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.create_entity import CreateEntityQuery from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.principal.groups.creation_information import ( GroupCreationInformation, ) @@ -11,7 +11,7 @@ from office365.sharepoint.utilities.principal_info import PrincipalInfo -class GroupCollection(BaseEntityCollection): +class GroupCollection(EntityCollection[Group]): """Represents a collection of Group resources.""" def __init__(self, context, resource_path=None): @@ -24,7 +24,7 @@ def expand_to_principals(self, max_count): :param int max_count: Specifies the maximum number of principals to be returned. """ return_type = ClientResult(self.context, ClientValueCollection(PrincipalInfo)) - for cur_grp in self: # type: Group + for cur_grp in self: return_type = cur_grp.expand_to_principals(max_count) return return_type diff --git a/office365/sharepoint/principal/principal.py b/office365/sharepoint/principal/principal.py index 5d98d54b3..66b5421e1 100644 --- a/office365/sharepoint/principal/principal.py +++ b/office365/sharepoint/principal/principal.py @@ -1,8 +1,8 @@ from office365.runtime.paths.service_operation import ServiceOperationPath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class Principal(BaseEntity): +class Principal(Entity): """Represents a user or group that can be assigned permissions to control security.""" @property diff --git a/office365/sharepoint/principal/users/collection.py b/office365/sharepoint/principal/users/collection.py index 35fdcf07f..9f3407d37 100644 --- a/office365/sharepoint/principal/users/collection.py +++ b/office365/sharepoint/principal/users/collection.py @@ -1,11 +1,11 @@ from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.create_entity import CreateEntityQuery from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.principal.users.user import User -class UserCollection(BaseEntityCollection): +class UserCollection(EntityCollection[User]): def __init__(self, context, resource_path=None): """Represents a collection of User resources.""" super(UserCollection, self).__init__(context, User, resource_path) diff --git a/office365/sharepoint/publishing/announcements/controller.py b/office365/sharepoint/publishing/announcements/controller.py index 797cfa04e..7fc646e22 100644 --- a/office365/sharepoint/publishing/announcements/controller.py +++ b/office365/sharepoint/publishing/announcements/controller.py @@ -1,8 +1,8 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class AnnouncementsController(BaseEntity): +class AnnouncementsController(Entity): def __init__(self, context, path=None): if path is None: path = ResourcePath("SP.Publishing.AnnouncementsController") diff --git a/office365/sharepoint/publishing/customproperties/base.py b/office365/sharepoint/publishing/customproperties/base.py index 2cc2b28e9..a395dcb7f 100644 --- a/office365/sharepoint/publishing/customproperties/base.py +++ b/office365/sharepoint/publishing/customproperties/base.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class BaseCustomProperty(BaseEntity): +class BaseCustomProperty(Entity): @property def entity_type_name(self): return "Microsoft.SharePoint.Publishing.RestOnly.BaseCustomProperty" diff --git a/office365/sharepoint/publishing/diagnostics/controller.py b/office365/sharepoint/publishing/diagnostics/controller.py index a6bfef075..83ff7a2e8 100644 --- a/office365/sharepoint/publishing/diagnostics/controller.py +++ b/office365/sharepoint/publishing/diagnostics/controller.py @@ -1,11 +1,11 @@ from office365.runtime.client_result import ClientResult from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.publishing.diagnostics.page_diagnostics import PageDiagnostics -class PageDiagnosticsController(BaseEntity): +class PageDiagnosticsController(Entity): def __init__(self, context): static_path = ResourcePath("SP.Publishing.PageDiagnosticsController") super(PageDiagnosticsController, self).__init__(context, static_path) diff --git a/office365/sharepoint/publishing/embed_data_v1.py b/office365/sharepoint/publishing/embed_data_v1.py index 9a0dd0234..b6550162b 100644 --- a/office365/sharepoint/publishing/embed_data_v1.py +++ b/office365/sharepoint/publishing/embed_data_v1.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class EmbedDataV1(BaseEntity): +class EmbedDataV1(Entity): """Represents embedded meta data of the page.""" def url(self): diff --git a/office365/sharepoint/publishing/embed_service.py b/office365/sharepoint/publishing/embed_service.py index 740d86f2b..13bc0f5cd 100644 --- a/office365/sharepoint/publishing/embed_service.py +++ b/office365/sharepoint/publishing/embed_service.py @@ -1,9 +1,9 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.publishing.embed_data_v1 import EmbedDataV1 -class EmbedService(BaseEntity): +class EmbedService(Entity): """The class was used to get embed meta data for the page.""" def embed_data(self, url, version=1): diff --git a/office365/sharepoint/publishing/highlights_info.py b/office365/sharepoint/publishing/highlights_info.py index 86f7f6fce..40c697e9c 100644 --- a/office365/sharepoint/publishing/highlights_info.py +++ b/office365/sharepoint/publishing/highlights_info.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class HighlightsInfo(BaseEntity): +class HighlightsInfo(Entity): """""" @property diff --git a/office365/sharepoint/publishing/navigation/structural_navigation_cache_wrapper.py b/office365/sharepoint/publishing/navigation/structural_navigation_cache_wrapper.py index 595d6e8d5..20774b596 100644 --- a/office365/sharepoint/publishing/navigation/structural_navigation_cache_wrapper.py +++ b/office365/sharepoint/publishing/navigation/structural_navigation_cache_wrapper.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class StructuralNavigationCacheWrapper(BaseEntity): +class StructuralNavigationCacheWrapper(Entity): @property def entity_type_name(self): return "SP.Publishing.Navigation.StructuralNavigationCacheWrapper" diff --git a/office365/sharepoint/publishing/pagecopywithassets/response.py b/office365/sharepoint/publishing/pagecopywithassets/response.py index 77b1e5b5b..72a4c6293 100644 --- a/office365/sharepoint/publishing/pagecopywithassets/response.py +++ b/office365/sharepoint/publishing/pagecopywithassets/response.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class PageCopyResponse(BaseEntity): +class PageCopyResponse(Entity): @property def entity_type_name(self): return "Microsoft.SharePoint.Publishing.PageCopyWithAssets.PageCopyResponse" diff --git a/office365/sharepoint/publishing/pages/metadata.py b/office365/sharepoint/publishing/pages/metadata.py index 4003b9bee..f0c3bcc7e 100644 --- a/office365/sharepoint/publishing/pages/metadata.py +++ b/office365/sharepoint/publishing/pages/metadata.py @@ -1,10 +1,10 @@ from office365.runtime.types.collections import StringCollection -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.publishing.pages.version_info import SitePageVersionInfo from office365.sharepoint.publishing.user_info import UserInfo -class SitePageMetadata(BaseEntity): +class SitePageMetadata(Entity): """Represents the core properties of a Site Page.""" @property diff --git a/office365/sharepoint/publishing/pages/metadata_collection.py b/office365/sharepoint/publishing/pages/metadata_collection.py index 9382ead8c..b8451c021 100644 --- a/office365/sharepoint/publishing/pages/metadata_collection.py +++ b/office365/sharepoint/publishing/pages/metadata_collection.py @@ -1,9 +1,9 @@ from office365.runtime.paths.service_operation import ServiceOperationPath -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.publishing.pages.metadata import SitePageMetadata -class SitePageMetadataCollection(BaseEntityCollection): +class SitePageMetadataCollection(EntityCollection): """Specifies a collection of site pages.""" def get_by_id(self, site_page_id): diff --git a/office365/sharepoint/publishing/pages/move_response.py b/office365/sharepoint/publishing/pages/move_response.py index cf16a1123..0559325c2 100644 --- a/office365/sharepoint/publishing/pages/move_response.py +++ b/office365/sharepoint/publishing/pages/move_response.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class PageMoveResponse(BaseEntity): +class PageMoveResponse(Entity): """""" @property diff --git a/office365/sharepoint/publishing/pages/reposts/collection.py b/office365/sharepoint/publishing/pages/reposts/collection.py index b6ba471be..761c897aa 100644 --- a/office365/sharepoint/publishing/pages/reposts/collection.py +++ b/office365/sharepoint/publishing/pages/reposts/collection.py @@ -1,10 +1,10 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.publishing.pages.reposts.repost import RepostPage -class RepostPageCollection(BaseEntityCollection): +class RepostPageCollection(EntityCollection): def __init__(self, context, resource_path=None): super(RepostPageCollection, self).__init__(context, RepostPage, resource_path) diff --git a/office365/sharepoint/publishing/pages/service.py b/office365/sharepoint/publishing/pages/service.py index 7aafff35f..252d1bdd2 100644 --- a/office365/sharepoint/publishing/pages/service.py +++ b/office365/sharepoint/publishing/pages/service.py @@ -3,7 +3,7 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery from office365.runtime.types.collections import StringCollection from office365.sharepoint.administration.orgassets.org_assets import OrgAssets -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.files.file import File from office365.sharepoint.publishing.file_picker_options import FilePickerOptions from office365.sharepoint.publishing.pages.collection import SitePageCollection @@ -11,7 +11,7 @@ from office365.sharepoint.publishing.sites.communication.site import CommunicationSite -class SitePageService(BaseEntity): +class SitePageService(Entity): """Represents a set of APIs to use for managing site pages.""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/publishing/pages/topics/collection.py b/office365/sharepoint/publishing/pages/topics/collection.py index 67ea65f0a..d7c47d501 100644 --- a/office365/sharepoint/publishing/pages/topics/collection.py +++ b/office365/sharepoint/publishing/pages/topics/collection.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.publishing.pages.topics.topic import TopicSitePage -class TopicPageCollection(BaseEntityCollection): +class TopicPageCollection(EntityCollection): def __init__(self, context, resource_path=None): super(TopicPageCollection, self).__init__(context, TopicSitePage, resource_path) diff --git a/office365/sharepoint/publishing/personmagazine/person_magazine.py b/office365/sharepoint/publishing/personmagazine/person_magazine.py index f9e7169a5..7f63fce05 100644 --- a/office365/sharepoint/publishing/personmagazine/person_magazine.py +++ b/office365/sharepoint/publishing/personmagazine/person_magazine.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class PersonMagazine(BaseEntity): +class PersonMagazine(Entity): @property def entity_type_name(self): return "SP.Publishing.PersonMagazine" diff --git a/office365/sharepoint/publishing/point/site_manager.py b/office365/sharepoint/publishing/point/site_manager.py index 2e4f3f637..f7cd7cf43 100644 --- a/office365/sharepoint/publishing/point/site_manager.py +++ b/office365/sharepoint/publishing/point/site_manager.py @@ -1,8 +1,8 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class PointPublishingSiteManager(BaseEntity): +class PointPublishingSiteManager(Entity): """""" def __init__(self, context): diff --git a/office365/sharepoint/publishing/point/site_status.py b/office365/sharepoint/publishing/point/site_status.py index 6896cd273..b3ae703d2 100644 --- a/office365/sharepoint/publishing/point/site_status.py +++ b/office365/sharepoint/publishing/point/site_status.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class PointPublishingSiteStatus(BaseEntity): +class PointPublishingSiteStatus(Entity): @property def entity_type_name(self): return "SP.Publishing.PointPublishingSiteStatus" diff --git a/office365/sharepoint/publishing/portallaunch/waves_manager.py b/office365/sharepoint/publishing/portallaunch/waves_manager.py index a0415b164..1ac1c1a2f 100644 --- a/office365/sharepoint/publishing/portallaunch/waves_manager.py +++ b/office365/sharepoint/publishing/portallaunch/waves_manager.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class WavesManager(BaseEntity): +class WavesManager(Entity): @property def entity_type_name(self): return "SP.Publishing.PortalLaunch.WavesManager" diff --git a/office365/sharepoint/publishing/primary_city_time.py b/office365/sharepoint/publishing/primary_city_time.py index 56e7c3aff..20d9c88cd 100644 --- a/office365/sharepoint/publishing/primary_city_time.py +++ b/office365/sharepoint/publishing/primary_city_time.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class PrimaryCityTime(BaseEntity): +class PrimaryCityTime(Entity): """Represents the date and time, in UTC, of the geographic location.""" @property diff --git a/office365/sharepoint/publishing/rich_sharing.py b/office365/sharepoint/publishing/rich_sharing.py index 099c653cc..b1b8fab63 100644 --- a/office365/sharepoint/publishing/rich_sharing.py +++ b/office365/sharepoint/publishing/rich_sharing.py @@ -1,10 +1,10 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery from office365.runtime.types.collections import StringCollection -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class RichSharing(BaseEntity): +class RichSharing(Entity): def __init__(self, context, resource_path=None): if resource_path is None: resource_path = ResourcePath("SP.Publishing.RichSharing") diff --git a/office365/sharepoint/publishing/search.py b/office365/sharepoint/publishing/search.py index a58ed6b53..9d95bf5db 100644 --- a/office365/sharepoint/publishing/search.py +++ b/office365/sharepoint/publishing/search.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class Search(BaseEntity): +class Search(Entity): @property def entity_type_name(self): return "SP.Publishing.Search" diff --git a/office365/sharepoint/publishing/sites/communication/site.py b/office365/sharepoint/publishing/sites/communication/site.py index c989e60dc..165ede902 100644 --- a/office365/sharepoint/publishing/sites/communication/site.py +++ b/office365/sharepoint/publishing/sites/communication/site.py @@ -1,7 +1,7 @@ from office365.runtime.client_result import ClientResult from office365.runtime.http.http_method import HttpMethod from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.publishing.sites.communication.creation_request import ( CommunicationSiteCreationRequest, ) @@ -10,7 +10,7 @@ ) -class CommunicationSite(BaseEntity): +class CommunicationSite(Entity): """Represents a Communication Site.""" def create(self, title, site_url, description=None): diff --git a/office365/sharepoint/publishing/video/channel.py b/office365/sharepoint/publishing/video/channel.py index 6cc5485b2..5e1ef3e4a 100644 --- a/office365/sharepoint/publishing/video/channel.py +++ b/office365/sharepoint/publishing/video/channel.py @@ -1,9 +1,9 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class VideoChannel(BaseEntity): +class VideoChannel(Entity): def get_video_count(self): return_type = ClientResult(self.context) qry = ServiceOperationQuery( diff --git a/office365/sharepoint/publishing/video/channel_collection.py b/office365/sharepoint/publishing/video/channel_collection.py index afecd2e87..a5c0d5ed8 100644 --- a/office365/sharepoint/publishing/video/channel_collection.py +++ b/office365/sharepoint/publishing/video/channel_collection.py @@ -1,8 +1,8 @@ -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.publishing.video.channel import VideoChannel -class VideoChannelCollection(BaseEntityCollection): +class VideoChannelCollection(EntityCollection): def __init__(self, context, resource_path=None): super(VideoChannelCollection, self).__init__( context, VideoChannel, resource_path diff --git a/office365/sharepoint/publishing/video/item.py b/office365/sharepoint/publishing/video/item.py index a314ab1ed..1272a60b3 100644 --- a/office365/sharepoint/publishing/video/item.py +++ b/office365/sharepoint/publishing/video/item.py @@ -1,9 +1,9 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class VideoItem(BaseEntity): +class VideoItem(Entity): def get_video_embed_code( self, width, height, autoplay=True, show_info=True, make_responsive=True ): diff --git a/office365/sharepoint/publishing/video/item_collection.py b/office365/sharepoint/publishing/video/item_collection.py index f9d080ab0..d6c88c780 100644 --- a/office365/sharepoint/publishing/video/item_collection.py +++ b/office365/sharepoint/publishing/video/item_collection.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.publishing.video.item import VideoItem -class VideoItemCollection(BaseEntityCollection): +class VideoItemCollection(EntityCollection): def __init__(self, context, resource_path=None): super(VideoItemCollection, self).__init__(context, VideoItem, resource_path) diff --git a/office365/sharepoint/publishing/video/service_discoverer.py b/office365/sharepoint/publishing/video/service_discoverer.py index 471891625..a435546d8 100644 --- a/office365/sharepoint/publishing/video/service_discoverer.py +++ b/office365/sharepoint/publishing/video/service_discoverer.py @@ -1,8 +1,8 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class VideoServiceDiscoverer(BaseEntity): +class VideoServiceDiscoverer(Entity): def __init__(self, context): super(VideoServiceDiscoverer, self).__init__( context, ResourcePath("SP.Publishing.VideoServiceDiscoverer") diff --git a/office365/sharepoint/publishing/video/service_manager.py b/office365/sharepoint/publishing/video/service_manager.py index 9959b8787..81c611acf 100644 --- a/office365/sharepoint/publishing/video/service_manager.py +++ b/office365/sharepoint/publishing/video/service_manager.py @@ -1,12 +1,12 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.publishing.video.channel_collection import ( VideoChannelCollection, ) -class VideoServiceManager(BaseEntity): +class VideoServiceManager(Entity): def __init__(self, context): super(VideoServiceManager, self).__init__( context, ResourcePath("SP.Publishing.VideoServiceManager") diff --git a/office365/sharepoint/pushnotifications/collection.py b/office365/sharepoint/pushnotifications/collection.py index eb9708f5c..66c4724b1 100644 --- a/office365/sharepoint/pushnotifications/collection.py +++ b/office365/sharepoint/pushnotifications/collection.py @@ -1,9 +1,9 @@ from office365.runtime.paths.service_operation import ServiceOperationPath -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.pushnotifications.subscriber import PushNotificationSubscriber -class PushNotificationSubscriberCollection(BaseEntityCollection): +class PushNotificationSubscriberCollection(EntityCollection): """Specifies the collection of push notification subscribers for the site""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/pushnotifications/subscriber.py b/office365/sharepoint/pushnotifications/subscriber.py index d199b176f..a7345ec2a 100644 --- a/office365/sharepoint/pushnotifications/subscriber.py +++ b/office365/sharepoint/pushnotifications/subscriber.py @@ -1,10 +1,10 @@ import datetime from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class PushNotificationSubscriber(BaseEntity): +class PushNotificationSubscriber(Entity): """Represents a push notification subscriber over a site.""" @property diff --git a/office365/sharepoint/recyclebin/item.py b/office365/sharepoint/recyclebin/item.py index a71da7439..f9f6da0ef 100644 --- a/office365/sharepoint/recyclebin/item.py +++ b/office365/sharepoint/recyclebin/item.py @@ -1,11 +1,11 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.principal.users.user import User -class RecycleBinItem(BaseEntity): +class RecycleBinItem(Entity): """Represents a Recycle Bin item in the Recycle Bin of a site or a site collection.""" def restore(self): diff --git a/office365/sharepoint/recyclebin/item_collection.py b/office365/sharepoint/recyclebin/item_collection.py index 3e84841b4..dca5a7eb7 100644 --- a/office365/sharepoint/recyclebin/item_collection.py +++ b/office365/sharepoint/recyclebin/item_collection.py @@ -1,11 +1,11 @@ from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.service_operation import ServiceOperationQuery from office365.runtime.types.collections import StringCollection -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.recyclebin.item import RecycleBinItem -class RecycleBinItemCollection(BaseEntityCollection): +class RecycleBinItemCollection(EntityCollection): """Represents a collection of View resources.""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/reputationmodel/reputation.py b/office365/sharepoint/reputationmodel/reputation.py index 3109d7526..0caef1c3f 100644 --- a/office365/sharepoint/reputationmodel/reputation.py +++ b/office365/sharepoint/reputationmodel/reputation.py @@ -1,9 +1,9 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class Reputation(BaseEntity): +class Reputation(Entity): """The Reputation static type includes methods to set the reputation properties on a list item.""" @staticmethod diff --git a/office365/sharepoint/request_user_context.py b/office365/sharepoint/request_user_context.py index 90eca2896..32f66e8dc 100644 --- a/office365/sharepoint/request_user_context.py +++ b/office365/sharepoint/request_user_context.py @@ -1,8 +1,8 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class RequestUserContext(BaseEntity): +class RequestUserContext(Entity): """The class that represents the user context for the present request. Typically found under /_api/me""" @property diff --git a/office365/sharepoint/search/administration/document_crawl_log.py b/office365/sharepoint/search/administration/document_crawl_log.py index f16e6b40a..269e6efcf 100644 --- a/office365/sharepoint/search/administration/document_crawl_log.py +++ b/office365/sharepoint/search/administration/document_crawl_log.py @@ -1,11 +1,11 @@ from office365.runtime.client_result import ClientResult from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.search.simple_data_table import SimpleDataTable -class DocumentCrawlLog(BaseEntity): +class DocumentCrawlLog(Entity): """This object contains methods that can be used by the protocol client to retrieve information about items that were crawled.""" diff --git a/office365/sharepoint/search/administration/site_content_processing_info_provider.py b/office365/sharepoint/search/administration/site_content_processing_info_provider.py index 9593f8340..e262d5a45 100644 --- a/office365/sharepoint/search/administration/site_content_processing_info_provider.py +++ b/office365/sharepoint/search/administration/site_content_processing_info_provider.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SiteContentProcessingInfoProvider(BaseEntity): +class SiteContentProcessingInfoProvider(Entity): @property def entity_type_name(self): return "Microsoft.SharePoint.Client.Search.Administration.SiteContentProcessingInfoProvider" diff --git a/office365/sharepoint/search/administration/site_me_ta_info_provider.py b/office365/sharepoint/search/administration/site_me_ta_info_provider.py index 749441461..7f57db668 100644 --- a/office365/sharepoint/search/administration/site_me_ta_info_provider.py +++ b/office365/sharepoint/search/administration/site_me_ta_info_provider.py @@ -1,9 +1,9 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SiteMeTAInfoProvider(BaseEntity): +class SiteMeTAInfoProvider(Entity): """""" def get_azure_container_sas_token(self): diff --git a/office365/sharepoint/search/administration/tenant_crawl_versions_info_provider.py b/office365/sharepoint/search/administration/tenant_crawl_versions_info_provider.py index cefbb720a..8e368a9b3 100644 --- a/office365/sharepoint/search/administration/tenant_crawl_versions_info_provider.py +++ b/office365/sharepoint/search/administration/tenant_crawl_versions_info_provider.py @@ -1,9 +1,9 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class TenantCrawlVersionsInfoProvider(BaseEntity): +class TenantCrawlVersionsInfoProvider(Entity): """ """ def disable_crawl_versions(self, site_id): diff --git a/office365/sharepoint/search/analytics/signal_store.py b/office365/sharepoint/search/analytics/signal_store.py index 3e56a368f..dcc03d661 100644 --- a/office365/sharepoint/search/analytics/signal_store.py +++ b/office365/sharepoint/search/analytics/signal_store.py @@ -1,8 +1,8 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SignalStore(BaseEntity): +class SignalStore(Entity): """Provides methods for managing the analytics signal store.""" def __init__(self, context, resource_path): diff --git a/office365/sharepoint/search/query/personalization_data.py b/office365/sharepoint/search/query/personalization_data.py index b35172f71..dcb6e5c27 100644 --- a/office365/sharepoint/search/query/personalization_data.py +++ b/office365/sharepoint/search/query/personalization_data.py @@ -1,8 +1,8 @@ from office365.runtime.paths.service_operation import ServiceOperationPath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class QueryPersonalizationData(BaseEntity): +class QueryPersonalizationData(Entity): """Contains a unique identifier for the current user who is executing a search query""" def __init__(self, context, user_id): diff --git a/office365/sharepoint/search/query/sort/collection.py b/office365/sharepoint/search/query/sort/collection.py index 1ce8211f2..3c06f9510 100644 --- a/office365/sharepoint/search/query/sort/collection.py +++ b/office365/sharepoint/search/query/sort/collection.py @@ -1,10 +1,10 @@ from office365.runtime.client_value_collection import ClientValueCollection from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.search.query.sort.sort import Sort -class SortCollection(BaseEntity): +class SortCollection(Entity): """Contains information about how to sort the search results.""" def add(self, property_name, direction): diff --git a/office365/sharepoint/search/ranking_labeling.py b/office365/sharepoint/search/ranking_labeling.py index 0b585ef04..e92a9717a 100644 --- a/office365/sharepoint/search/ranking_labeling.py +++ b/office365/sharepoint/search/ranking_labeling.py @@ -1,10 +1,10 @@ from office365.runtime.client_result import ClientResult from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class RankingLabeling(BaseEntity): +class RankingLabeling(Entity): """Provides methods for getting and adding relevance judgments""" def __init__(self, context): diff --git a/office365/sharepoint/search/reordering_rule_collection.py b/office365/sharepoint/search/reordering_rule_collection.py index c1dd72030..299543320 100644 --- a/office365/sharepoint/search/reordering_rule_collection.py +++ b/office365/sharepoint/search/reordering_rule_collection.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class ReorderingRuleCollection(BaseEntity): +class ReorderingRuleCollection(Entity): """Contains information about how to reorder the search results.""" @property diff --git a/office365/sharepoint/search/service.py b/office365/sharepoint/search/service.py index bf6dcd0ef..93a6893bd 100644 --- a/office365/sharepoint/search/service.py +++ b/office365/sharepoint/search/service.py @@ -4,7 +4,7 @@ from office365.runtime.queries.function import FunctionQuery from office365.runtime.queries.service_operation import ServiceOperationQuery from office365.runtime.types.collections import StringCollection -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.principal.users.user import User from office365.sharepoint.search.query.auto_completion_results import ( QueryAutoCompletionResults, @@ -19,7 +19,7 @@ from office365.sharepoint.search.result import SearchResult -class SearchService(BaseEntity): +class SearchService(Entity): """SearchService exposes OData Service Operations.""" def __init__(self, context): diff --git a/office365/sharepoint/search/setting.py b/office365/sharepoint/search/setting.py index 3da4ed2b5..603f1d41d 100644 --- a/office365/sharepoint/search/setting.py +++ b/office365/sharepoint/search/setting.py @@ -1,7 +1,7 @@ from office365.runtime.client_result import ClientResult from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.search.promoted_results_operations_result import ( PromotedResultsOperationsResult, ) @@ -9,7 +9,7 @@ from office365.sharepoint.search.reports.base import ReportBase -class SearchSetting(BaseEntity): +class SearchSetting(Entity): """This object provides the REST operations defined under search settings.""" def __init__(self, context): diff --git a/office365/sharepoint/securestore/target_application.py b/office365/sharepoint/securestore/target_application.py index 314783f8b..46b051938 100644 --- a/office365/sharepoint/securestore/target_application.py +++ b/office365/sharepoint/securestore/target_application.py @@ -1,8 +1,8 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class TargetApplication(BaseEntity): +class TargetApplication(Entity): """A logical entity that represents a software system for which credentials are maintained. It consists of metadata including the number and type of credentials that are required by the software system and a set of claims (2) that identify the administrators who can update, read, and delete the entity. diff --git a/office365/sharepoint/securestore/target_application_field.py b/office365/sharepoint/securestore/target_application_field.py index f0598cea3..4b844c33c 100644 --- a/office365/sharepoint/securestore/target_application_field.py +++ b/office365/sharepoint/securestore/target_application_field.py @@ -1,8 +1,8 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class TargetApplicationField(BaseEntity): +class TargetApplicationField(Entity): """A name of a credential field and its associated credential type.""" @staticmethod diff --git a/office365/sharepoint/server_settings.py b/office365/sharepoint/server_settings.py index 7ebaaa725..e51ad4a1d 100644 --- a/office365/sharepoint/server_settings.py +++ b/office365/sharepoint/server_settings.py @@ -2,11 +2,11 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery from office365.runtime.types.collections import StringCollection -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.sites.language_collection import LanguageCollection -class ServerSettings(BaseEntity): +class ServerSettings(Entity): """Provides methods for obtaining server properties.""" def __init__(self, context): diff --git a/office365/sharepoint/sharing/document_manager.py b/office365/sharepoint/sharing/document_manager.py index 4ef50b96a..c00e0ee07 100644 --- a/office365/sharepoint/sharing/document_manager.py +++ b/office365/sharepoint/sharing/document_manager.py @@ -1,7 +1,7 @@ from office365.runtime.client_result import ClientResult from office365.runtime.client_value_collection import ClientValueCollection from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.permissions.roles.definitions.definition import RoleDefinition from office365.sharepoint.sharing.user_role_assignment import UserRoleAssignment from office365.sharepoint.sharing.user_sharing_result import UserSharingResult @@ -10,7 +10,7 @@ ) -class DocumentSharingManager(BaseEntity): +class DocumentSharingManager(Entity): """Specifies document sharing related methods.""" @staticmethod diff --git a/office365/sharepoint/sharing/information.py b/office365/sharepoint/sharing/information.py index aee168aff..441ebe2ab 100644 --- a/office365/sharepoint/sharing/information.py +++ b/office365/sharepoint/sharing/information.py @@ -1,5 +1,5 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.sharing.abilities import SharingAbilities from office365.sharepoint.sharing.access_request_settings import AccessRequestSettings from office365.sharepoint.sharing.links.default_templates_collection import ( @@ -8,7 +8,7 @@ from office365.sharepoint.sharing.picker_settings import PickerSettings -class SharingInformation(BaseEntity): +class SharingInformation(Entity): """Represents a response for Microsoft.SharePoint.Client.Sharing.SecurableObjectExtensions.GetSharingInformation. The accessRequestSettings, domainRestrictionSettings and permissionsInformation properties are not included in the default scalar property set for this type. diff --git a/office365/sharepoint/sharing/object_sharing_information.py b/office365/sharepoint/sharing/object_sharing_information.py index f68899f4b..a81d5bb7c 100644 --- a/office365/sharepoint/sharing/object_sharing_information.py +++ b/office365/sharepoint/sharing/object_sharing_information.py @@ -2,15 +2,15 @@ from office365.runtime.client_value_collection import ClientValueCollection from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity import Entity +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.sharing.links.info import SharingLinkInfo from office365.sharepoint.sharing.object_sharing_information_user import ( ObjectSharingInformationUser, ) -class ObjectSharingInformation(BaseEntity): +class ObjectSharingInformation(Entity): """Provides information about the sharing state of a securable object.""" @staticmethod @@ -103,7 +103,7 @@ def get_web_sharing_information( def get_shared_with_users(self): """Returns an array that contains the users with whom a securable object is shared.""" - return_type = BaseEntityCollection(self.context, ObjectSharingInformationUser) + return_type = EntityCollection(self.context, ObjectSharingInformationUser) qry = ServiceOperationQuery( self, "GetSharedWithUsers", None, None, None, return_type ) @@ -245,7 +245,7 @@ def shared_with_users_collection(self): """A collection of shared with users.""" return self.properties.get( "SharedWithUsersCollection", - BaseEntityCollection( + EntityCollection( self.context, ObjectSharingInformationUser, ResourcePath("SharedWithUsersCollection", self.resource_path), diff --git a/office365/sharepoint/sharing/object_sharing_information_user.py b/office365/sharepoint/sharing/object_sharing_information_user.py index 40f120fd2..e7fbfb985 100644 --- a/office365/sharepoint/sharing/object_sharing_information_user.py +++ b/office365/sharepoint/sharing/object_sharing_information_user.py @@ -1,10 +1,10 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.principal.principal import Principal from office365.sharepoint.principal.users.user import User -class ObjectSharingInformationUser(BaseEntity): +class ObjectSharingInformationUser(Entity): """Contains information about a principal with whom a securable object is shared. It can be a user or a group.""" @property diff --git a/office365/sharepoint/sharing/object_sharing_settings.py b/office365/sharepoint/sharing/object_sharing_settings.py index 98e5c06ee..72fc1a3ac 100644 --- a/office365/sharepoint/sharing/object_sharing_settings.py +++ b/office365/sharepoint/sharing/object_sharing_settings.py @@ -1,5 +1,5 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.sharing.object_sharing_information import ( ObjectSharingInformation, ) @@ -11,7 +11,7 @@ ) -class ObjectSharingSettings(BaseEntity): +class ObjectSharingSettings(Entity): """This class contains the information necessary to read and change the sharing status of a SharePoint object. It also contains a reference to SharePoint specific settings denoted by "SharePointSettings". """ diff --git a/office365/sharepoint/sharing/permission_information.py b/office365/sharepoint/sharing/permission_information.py index 1e8099909..832e35710 100644 --- a/office365/sharepoint/sharing/permission_information.py +++ b/office365/sharepoint/sharing/permission_information.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SharingPermissionInformation(BaseEntity): +class SharingPermissionInformation(Entity): """ Contains information about a sharing permission entity such as group or role. """ diff --git a/office365/sharepoint/sharing/personal_web.py b/office365/sharepoint/sharing/personal_web.py index 637631436..6407e846c 100644 --- a/office365/sharepoint/sharing/personal_web.py +++ b/office365/sharepoint/sharing/personal_web.py @@ -1,8 +1,8 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class PersonalWeb(BaseEntity): +class PersonalWeb(Entity): """Microsoft.SharePoint.Client.Sharing.PersonalWeb namespace represents methods that apply to a Web site for individual users. Methods act on the users default document library.""" diff --git a/office365/sharepoint/sharing/picker_settings.py b/office365/sharepoint/sharing/picker_settings.py index be06ef6f6..407d0ece1 100644 --- a/office365/sharepoint/sharing/picker_settings.py +++ b/office365/sharepoint/sharing/picker_settings.py @@ -1,10 +1,10 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.ui.applicationpages.peoplepicker.query_settings import ( PeoplePickerQuerySettings, ) -class PickerSettings(BaseEntity): +class PickerSettings(Entity): """ This class contains configuration settings for the client people picker control hosted by the SharePoint sharing UI. diff --git a/office365/sharepoint/sharing/result.py b/office365/sharepoint/sharing/result.py index 16e826e72..1205267d1 100644 --- a/office365/sharepoint/sharing/result.py +++ b/office365/sharepoint/sharing/result.py @@ -1,6 +1,6 @@ from office365.runtime.client_value_collection import ClientValueCollection from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.principal.groups.collection import GroupCollection from office365.sharepoint.sharing.invitation.creation_result import ( SPInvitationCreationResult, @@ -8,7 +8,7 @@ from office365.sharepoint.sharing.user_sharing_result import UserSharingResult -class SharingResult(BaseEntity): +class SharingResult(Entity): """Contains properties generated as a result of sharing.""" @property diff --git a/office365/sharepoint/sharing/securable_object_extensions.py b/office365/sharepoint/sharing/securable_object_extensions.py index 3e453f123..a87f5732e 100644 --- a/office365/sharepoint/sharing/securable_object_extensions.py +++ b/office365/sharepoint/sharing/securable_object_extensions.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SecurableObjectExtensions(BaseEntity): +class SecurableObjectExtensions(Entity): """Contains extension methods of securable object.""" @property diff --git a/office365/sharepoint/sharing/shared_document_info.py b/office365/sharepoint/sharing/shared_document_info.py index acd25956d..3b9b2ce04 100644 --- a/office365/sharepoint/sharing/shared_document_info.py +++ b/office365/sharepoint/sharing/shared_document_info.py @@ -1,8 +1,8 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.sharing.principal import Principal -class SharedDocumentInfo(BaseEntity): +class SharedDocumentInfo(Entity): """""" @property diff --git a/office365/sharepoint/sharing/sharepoint_sharing_settings.py b/office365/sharepoint/sharing/sharepoint_sharing_settings.py index 77b03ebd3..07261143e 100644 --- a/office365/sharepoint/sharing/sharepoint_sharing_settings.py +++ b/office365/sharepoint/sharing/sharepoint_sharing_settings.py @@ -1,9 +1,9 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.sharing.picker_settings import PickerSettings -class SharePointSharingSettings(BaseEntity): +class SharePointSharingSettings(Entity): """This class contains the SharePoint UI-specific sharing settings.""" @property diff --git a/office365/sharepoint/sharing/site_sharing_report_helper.py b/office365/sharepoint/sharing/site_sharing_report_helper.py index a405259ed..d44e30990 100644 --- a/office365/sharepoint/sharing/site_sharing_report_helper.py +++ b/office365/sharepoint/sharing/site_sharing_report_helper.py @@ -1,6 +1,6 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.sharing.reports.site_capabilities import ( SiteSharingReportCapabilities, ) @@ -9,7 +9,7 @@ ) -class SiteSharingReportHelper(BaseEntity): +class SiteSharingReportHelper(Entity): @staticmethod def cancel_sharing_report_job(context): """ diff --git a/office365/sharepoint/sharing/utility.py b/office365/sharepoint/sharing/utility.py index 983e4c2f6..273ee9a16 100644 --- a/office365/sharepoint/sharing/utility.py +++ b/office365/sharepoint/sharing/utility.py @@ -1,11 +1,11 @@ from office365.runtime.client_result import ClientResult from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.sharing.user_directory_info import UserDirectoryInfo -class SharingUtility(BaseEntity): +class SharingUtility(Entity): """Provides sharing related utility methods.""" def __init__(self, context): diff --git a/office365/sharepoint/sharing/web_sharing_manager.py b/office365/sharepoint/sharing/web_sharing_manager.py index 9f4c13d08..ab5303ac2 100644 --- a/office365/sharepoint/sharing/web_sharing_manager.py +++ b/office365/sharepoint/sharing/web_sharing_manager.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class WebSharingManager(BaseEntity): +class WebSharingManager(Entity): """Specifies a placeholder for all web sharing methods.""" @property diff --git a/office365/sharepoint/sitedesigns/design_package_menu_contents.py b/office365/sharepoint/sitedesigns/design_package_menu_contents.py index 353889593..aa1b9e541 100644 --- a/office365/sharepoint/sitedesigns/design_package_menu_contents.py +++ b/office365/sharepoint/sitedesigns/design_package_menu_contents.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class DesignPackageMenuContents(BaseEntity): +class DesignPackageMenuContents(Entity): @property def entity_type_name(self): return "Microsoft.SharePoint.Utilities.WebTemplateExtensions.DesignPackageMenuContents" diff --git a/office365/sharepoint/sitedesigns/principal.py b/office365/sharepoint/sitedesigns/principal.py index 2396eec41..e90981487 100644 --- a/office365/sharepoint/sitedesigns/principal.py +++ b/office365/sharepoint/sitedesigns/principal.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SiteDesignPrincipal(BaseEntity): +class SiteDesignPrincipal(Entity): @property def entity_type_name(self): return ( diff --git a/office365/sharepoint/sitedesigns/run.py b/office365/sharepoint/sitedesigns/run.py index 136a65974..65ed5c220 100644 --- a/office365/sharepoint/sitedesigns/run.py +++ b/office365/sharepoint/sitedesigns/run.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SiteDesignRun(BaseEntity): +class SiteDesignRun(Entity): @property def site_design_id(self): """ diff --git a/office365/sharepoint/sitehealth/summary.py b/office365/sharepoint/sitehealth/summary.py index 353d4ad68..0df47c6ac 100644 --- a/office365/sharepoint/sitehealth/summary.py +++ b/office365/sharepoint/sitehealth/summary.py @@ -1,9 +1,9 @@ from office365.runtime.client_value_collection import ClientValueCollection -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.sitehealth.result import SiteHealthResult -class SiteHealthSummary(BaseEntity): +class SiteHealthSummary(Entity): """Specifies a summary of the results of running a set of site collection health rules.""" @property diff --git a/office365/sharepoint/sites/language_collection.py b/office365/sharepoint/sites/language_collection.py index 81bc05115..5ed0edec1 100644 --- a/office365/sharepoint/sites/language_collection.py +++ b/office365/sharepoint/sites/language_collection.py @@ -1,9 +1,9 @@ from office365.runtime.client_value_collection import ClientValueCollection -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.sites.language import Language -class LanguageCollection(BaseEntity): +class LanguageCollection(Entity): """Represents a collection of SPLanguage objects""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/sites/site.py b/office365/sharepoint/sites/site.py index 7b81d9608..132750877 100644 --- a/office365/sharepoint/sites/site.py +++ b/office365/sharepoint/sites/site.py @@ -6,12 +6,12 @@ from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.service_operation import ServiceOperationQuery from office365.sharepoint.audit.audit import Audit -from office365.sharepoint.base_entity import BaseEntity -from office365.sharepoint.base_entity_collection import BaseEntityCollection from office365.sharepoint.changes.collection import ChangeCollection from office365.sharepoint.changes.token import ChangeToken from office365.sharepoint.compliance.store_proxy import SPPolicyStoreProxy from office365.sharepoint.compliance.tag import ComplianceTag +from office365.sharepoint.entity import Entity +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.eventreceivers.definition_collection import ( EventReceiverDefinitionCollection, ) @@ -38,7 +38,7 @@ from office365.sharepoint.webs.web import Web -class Site(BaseEntity): +class Site(Entity): """ Represents a collection of sites in a Web application, including a top-level website and all its sub sites. @@ -120,7 +120,7 @@ def _site_loaded(): def get_migration_status(self): """""" - return_type = BaseEntityCollection(self.context, SPMigrationJobStatus) + return_type = EntityCollection(self.context, SPMigrationJobStatus) qry = ServiceOperationQuery( self, "GetMigrationStatus", None, None, None, return_type ) diff --git a/office365/sharepoint/sites/sph_site.py b/office365/sharepoint/sites/sph_site.py index 340438766..039fb2dfc 100644 --- a/office365/sharepoint/sites/sph_site.py +++ b/office365/sharepoint/sites/sph_site.py @@ -1,11 +1,11 @@ from office365.runtime.client_result import ClientResult from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.sites.home_site_reference import SPHSiteReference -class SPHSite(BaseEntity): +class SPHSite(Entity): def __init__(self, context, resource_path=None): """ A home site represents a SharePoint communication site. diff --git a/office365/sharepoint/sites/team_site_data.py b/office365/sharepoint/sites/team_site_data.py index 4549c3b7d..5ac380ca5 100644 --- a/office365/sharepoint/sites/team_site_data.py +++ b/office365/sharepoint/sites/team_site_data.py @@ -1,5 +1,5 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class TeamSiteData(BaseEntity): +class TeamSiteData(Entity): """""" diff --git a/office365/sharepoint/sites/version_policy_manager.py b/office365/sharepoint/sites/version_policy_manager.py index 3d44b42bd..c18d64dd3 100644 --- a/office365/sharepoint/sites/version_policy_manager.py +++ b/office365/sharepoint/sites/version_policy_manager.py @@ -1,5 +1,5 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SiteVersionPolicyManager(BaseEntity): +class SiteVersionPolicyManager(Entity): """""" diff --git a/office365/sharepoint/sitescripts/utility.py b/office365/sharepoint/sitescripts/utility.py index a500194c3..0f9df1fa5 100644 --- a/office365/sharepoint/sitescripts/utility.py +++ b/office365/sharepoint/sitescripts/utility.py @@ -2,8 +2,8 @@ from office365.runtime.client_value_collection import ClientValueCollection from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity import Entity +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.sitedesigns.metadata import SiteDesignMetadata from office365.sharepoint.sitedesigns.principal import SiteDesignPrincipal from office365.sharepoint.sitedesigns.task import SiteDesignTask @@ -14,7 +14,7 @@ ) -class SiteScriptUtility(BaseEntity): +class SiteScriptUtility(Entity): """Use class to automate provisioning new or existing modern SharePoint sites that use your own custom configurations. """ @@ -277,7 +277,7 @@ def get_site_design_rights(context, id_): :param office365.sharepoint.client_context.ClientContext context: SharePoint client context """ - return_type = BaseEntityCollection(context, SiteDesignPrincipal) + return_type = EntityCollection(context, SiteDesignPrincipal) utility = SiteScriptUtility(context) qry = ServiceOperationQuery( utility, "GetSiteDesignRights", [id_], None, None, return_type diff --git a/office365/sharepoint/social/announcement_manager.py b/office365/sharepoint/social/announcement_manager.py index 496638862..f358d8539 100644 --- a/office365/sharepoint/social/announcement_manager.py +++ b/office365/sharepoint/social/announcement_manager.py @@ -1,11 +1,11 @@ from office365.runtime.client_result import ClientResult from office365.runtime.client_value_collection import ClientValueCollection from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.webparts.tile_data import TileData -class SocialAnnouncementManager(BaseEntity): +class SocialAnnouncementManager(Entity): """Contains methods related to SharePoint Announcement Tiles""" @staticmethod diff --git a/office365/sharepoint/social/feed/manager.py b/office365/sharepoint/social/feed/manager.py index ae67f9f30..6ca47a35b 100644 --- a/office365/sharepoint/social/feed/manager.py +++ b/office365/sharepoint/social/feed/manager.py @@ -1,14 +1,14 @@ from office365.runtime.client_result import ClientResult from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.social.actor import SocialActor from office365.sharepoint.social.attachment import SocialAttachment from office365.sharepoint.social.feed.feed import SocialFeed from office365.sharepoint.social.thread import SocialThread -class SocialFeedManager(BaseEntity): +class SocialFeedManager(Entity): """The SocialFeedManager class provides access to social feeds. It provides methods to create posts, delete posts, read posts, and perform other operations on posts.""" diff --git a/office365/sharepoint/social/feed/rest.py b/office365/sharepoint/social/feed/rest.py index a4a5013a0..42bdaedb0 100644 --- a/office365/sharepoint/social/feed/rest.py +++ b/office365/sharepoint/social/feed/rest.py @@ -1,9 +1,9 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.social.feed.feed import SocialFeed -class SocialRestFeed(BaseEntity): +class SocialRestFeed(Entity): """ The SocialRestFeed class specifies a feed, which is an array of thread, each of which specifies a root post and an array of response posts. The SocialRestFeed type is available when the protocol client sends an OData diff --git a/office365/sharepoint/social/feed/rest_manager.py b/office365/sharepoint/social/feed/rest_manager.py index 180338b2f..b52fbb973 100644 --- a/office365/sharepoint/social/feed/rest_manager.py +++ b/office365/sharepoint/social/feed/rest_manager.py @@ -1,9 +1,9 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.social.rest_actor import SocialRestActor -class SocialRestFeedManager(BaseEntity): +class SocialRestFeedManager(Entity): """he SocialRestFeedManager class provides REST methods for creating posts, modifying threads, and consuming feeds on behalf of the current user. The SocialRestFeedManager class is available when the protocol client sends an OData request to a protocol server using [MS-CSOMREST]. diff --git a/office365/sharepoint/social/following/manager.py b/office365/sharepoint/social/following/manager.py index af5bd236e..61804b025 100644 --- a/office365/sharepoint/social/following/manager.py +++ b/office365/sharepoint/social/following/manager.py @@ -2,11 +2,11 @@ from office365.runtime.client_value_collection import ClientValueCollection from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.social.actor import SocialActor -class SocialFollowingManager(BaseEntity): +class SocialFollowingManager(Entity): """The SocialFollowingManager class provides properties and methods for managing a user's list of followed actors. Actors can be users, documents, sites, and tags.""" diff --git a/office365/sharepoint/social/following/rest_manager.py b/office365/sharepoint/social/following/rest_manager.py index 2885789b6..c53945b17 100644 --- a/office365/sharepoint/social/following/rest_manager.py +++ b/office365/sharepoint/social/following/rest_manager.py @@ -2,11 +2,11 @@ from office365.runtime.client_value_collection import ClientValueCollection from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.social.actor import SocialActor -class SocialRestFollowingManager(BaseEntity): +class SocialRestFollowingManager(Entity): """Provides methods for managing a user's list of followed actors (users, documents, sites, and tags).""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/social/rest_actor.py b/office365/sharepoint/social/rest_actor.py index dfd73819c..d40c9381e 100644 --- a/office365/sharepoint/social/rest_actor.py +++ b/office365/sharepoint/social/rest_actor.py @@ -1,8 +1,8 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.social.actor import SocialActor -class SocialRestActor(BaseEntity): +class SocialRestActor(Entity): """The SocialRestActor type contains information about an actor retrieved from server. An actor is a user, document, site, or tag. The SocialRestActor type is available when the protocol client sends an OData request to a protocol server using [MS-CSOMREST]. It is not available using [MS-CSOM].""" diff --git a/office365/sharepoint/social/rest_thread.py b/office365/sharepoint/social/rest_thread.py index 0a18ed667..01a32c073 100644 --- a/office365/sharepoint/social/rest_thread.py +++ b/office365/sharepoint/social/rest_thread.py @@ -1,10 +1,10 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.social.thread import SocialThread -class SocialRestThread(BaseEntity): +class SocialRestThread(Entity): """ The SocialRestThread class specifies a thread that is stored on the server. The thread contains a root post and zero or more reply posts. The SocialRestThread type is available when the protocol client sends an OData diff --git a/office365/sharepoint/social/switch.py b/office365/sharepoint/social/switch.py index 7ab0b60ac..2cca7158e 100644 --- a/office365/sharepoint/social/switch.py +++ b/office365/sharepoint/social/switch.py @@ -1,9 +1,9 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SPSocialSwitch(BaseEntity): +class SPSocialSwitch(Entity): """Provides methods to determine whether certain social features are enabled or disabled.""" @staticmethod diff --git a/office365/sharepoint/storagemetrics/storage_metrics.py b/office365/sharepoint/storagemetrics/storage_metrics.py index d799685f2..04a729fed 100644 --- a/office365/sharepoint/storagemetrics/storage_metrics.py +++ b/office365/sharepoint/storagemetrics/storage_metrics.py @@ -1,9 +1,9 @@ import datetime -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class StorageMetrics(BaseEntity): +class StorageMetrics(Entity): """Specifies the storage-related metrics for list folders in the site""" @property diff --git a/office365/sharepoint/teams/channel.py b/office365/sharepoint/teams/channel.py index e443b3b81..5a2b7d95f 100644 --- a/office365/sharepoint/teams/channel.py +++ b/office365/sharepoint/teams/channel.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class TeamChannel(BaseEntity): +class TeamChannel(Entity): @property def folder_id(self): """ diff --git a/office365/sharepoint/teams/channel_manager.py b/office365/sharepoint/teams/channel_manager.py index c78dac4f4..32e3abb9f 100644 --- a/office365/sharepoint/teams/channel_manager.py +++ b/office365/sharepoint/teams/channel_manager.py @@ -1,10 +1,10 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.sites.team_site_data import TeamSiteData from office365.sharepoint.teams.channel import TeamChannel -class TeamChannelManager(BaseEntity): +class TeamChannelManager(Entity): """This class is a placeholder for all TeamChannel related methods.""" @staticmethod diff --git a/office365/sharepoint/tenant/administration/endpoints.py b/office365/sharepoint/tenant/administration/endpoints.py index 30289e499..25ad6165a 100644 --- a/office365/sharepoint/tenant/administration/endpoints.py +++ b/office365/sharepoint/tenant/administration/endpoints.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class TenantAdminEndpoints(BaseEntity): +class TenantAdminEndpoints(Entity): @property def o365_admin_center_endpoint(self): """ diff --git a/office365/sharepoint/tenant/administration/hubsites/collection.py b/office365/sharepoint/tenant/administration/hubsites/collection.py index 376323ba8..6d0aa54f2 100644 --- a/office365/sharepoint/tenant/administration/hubsites/collection.py +++ b/office365/sharepoint/tenant/administration/hubsites/collection.py @@ -1,11 +1,11 @@ from office365.runtime.client_result import ClientResult from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.tenant.administration.hubsites.hub_site import HubSite -class HubSiteCollection(BaseEntityCollection): +class HubSiteCollection(EntityCollection): """Represents a collection of HubSite resources.""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/tenant/administration/hubsites/hub_site.py b/office365/sharepoint/tenant/administration/hubsites/hub_site.py index 50c12b98e..845ccd218 100644 --- a/office365/sharepoint/tenant/administration/hubsites/hub_site.py +++ b/office365/sharepoint/tenant/administration/hubsites/hub_site.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class HubSite(BaseEntity): +class HubSite(Entity): """SharePoint hub sites help you meet the needs of your organization by connecting and organizing sites""" @property diff --git a/office365/sharepoint/tenant/administration/hubsites/properties.py b/office365/sharepoint/tenant/administration/hubsites/properties.py index 62cdf899b..8c3a3de11 100644 --- a/office365/sharepoint/tenant/administration/hubsites/properties.py +++ b/office365/sharepoint/tenant/administration/hubsites/properties.py @@ -1,11 +1,11 @@ from office365.runtime.client_value_collection import ClientValueCollection -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.tenant.administration.hubsites.permission import ( HubSitePermission, ) -class HubSiteProperties(BaseEntity): +class HubSiteProperties(Entity): @property def permissions(self): return self.properties.get( diff --git a/office365/sharepoint/tenant/administration/insights/top_files_sharing.py b/office365/sharepoint/tenant/administration/insights/top_files_sharing.py index 5c6f5ff4e..66b69fab5 100644 --- a/office365/sharepoint/tenant/administration/insights/top_files_sharing.py +++ b/office365/sharepoint/tenant/administration/insights/top_files_sharing.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class TopFilesSharingInsights(BaseEntity): +class TopFilesSharingInsights(Entity): @property def entity_type_name(self): return ( diff --git a/office365/sharepoint/tenant/administration/internal/web_appservice_principal.py b/office365/sharepoint/tenant/administration/internal/web_appservice_principal.py index 02dd4b848..616f13ab5 100644 --- a/office365/sharepoint/tenant/administration/internal/web_appservice_principal.py +++ b/office365/sharepoint/tenant/administration/internal/web_appservice_principal.py @@ -1,9 +1,9 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SPOWebAppServicePrincipal(BaseEntity): +class SPOWebAppServicePrincipal(Entity): def __init__(self, context): stat_path = ResourcePath( "Microsoft.Online.SharePoint.TenantAdministration.Internal.SPOWebAppServicePrincipal" diff --git a/office365/sharepoint/tenant/administration/response_message_center.py b/office365/sharepoint/tenant/administration/response_message_center.py index 1d818d8cd..4b87a659f 100644 --- a/office365/sharepoint/tenant/administration/response_message_center.py +++ b/office365/sharepoint/tenant/administration/response_message_center.py @@ -1,8 +1,8 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class ResponseMessageCenter(BaseEntity): +class ResponseMessageCenter(Entity): def __init__(self, context): static_path = ResourcePath( "Microsoft.Online.SharePoint.TenantAdministration.ResponseMessageCenter" diff --git a/office365/sharepoint/tenant/administration/response_service_health.py b/office365/sharepoint/tenant/administration/response_service_health.py index dd3fff066..94bc4d79f 100644 --- a/office365/sharepoint/tenant/administration/response_service_health.py +++ b/office365/sharepoint/tenant/administration/response_service_health.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class ResponseServiceHealth(BaseEntity): +class ResponseServiceHealth(Entity): @property def entity_type_name(self): return "Microsoft.Online.SharePoint.TenantAdministration.ResponseServiceHealth" diff --git a/office365/sharepoint/tenant/administration/settings_service.py b/office365/sharepoint/tenant/administration/settings_service.py index 87ae037b7..fde738ca0 100644 --- a/office365/sharepoint/tenant/administration/settings_service.py +++ b/office365/sharepoint/tenant/administration/settings_service.py @@ -2,12 +2,12 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery from office365.runtime.types.collections import StringCollection -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.tenant.administration.smtp_server import SmtpServer from office365.sharepoint.tenant.administration.types import DisableGroupify -class TenantAdminSettingsService(BaseEntity): +class TenantAdminSettingsService(Entity): """""" def __init__(self, context): diff --git a/office365/sharepoint/tenant/administration/sites/properties.py b/office365/sharepoint/tenant/administration/sites/properties.py index 1ee98bbdb..2f1064441 100644 --- a/office365/sharepoint/tenant/administration/sites/properties.py +++ b/office365/sharepoint/tenant/administration/sites/properties.py @@ -1,14 +1,14 @@ from office365.runtime.paths.key import KeyPath from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.sites.site import Site from office365.sharepoint.tenant.administration.deny_add_and_customize_pages_status import ( DenyAddAndCustomizePagesStatus, ) -class SiteProperties(BaseEntity): +class SiteProperties(Entity): """Contains a property bag of information about a site.""" @staticmethod diff --git a/office365/sharepoint/tenant/administration/sites/properties_collection.py b/office365/sharepoint/tenant/administration/sites/properties_collection.py index 049f92c6b..aabd425be 100644 --- a/office365/sharepoint/tenant/administration/sites/properties_collection.py +++ b/office365/sharepoint/tenant/administration/sites/properties_collection.py @@ -1,13 +1,13 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.tenant.administration.sites.properties import SiteProperties from office365.sharepoint.tenant.administration.sites.state_properties import ( SiteStateProperties, ) -class SitePropertiesCollection(BaseEntityCollection): +class SitePropertiesCollection(EntityCollection): """SiteProperties resource collection""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/tenant/administration/tenant.py b/office365/sharepoint/tenant/administration/tenant.py index 46d647c8d..09865537a 100644 --- a/office365/sharepoint/tenant/administration/tenant.py +++ b/office365/sharepoint/tenant/administration/tenant.py @@ -4,8 +4,8 @@ from office365.runtime.client_value_collection import ClientValueCollection from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity import Entity +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.gtp.request_options import ChatGptRequestOptions from office365.sharepoint.listitems.collection import ListItemCollection from office365.sharepoint.lists.render_data_parameters import RenderListDataParameters @@ -59,7 +59,7 @@ from office365.sharepoint.tenant.settings import TenantSettings -class Tenant(BaseEntity): +class Tenant(Entity): """Represents a SharePoint tenant.""" def __init__(self, context): @@ -152,7 +152,7 @@ def get_top_files_sharing_insights(self, query_mode): :param int query_mode: """ payload = {"queryMode": query_mode} - return_type = BaseEntityCollection(self.context, TopFilesSharingInsights) + return_type = EntityCollection(self.context, TopFilesSharingInsights) qry = ServiceOperationQuery( self, "GetTopFilesSharingInsights", payload, None, None, return_type ) diff --git a/office365/sharepoint/tenant/administration/theme_properties.py b/office365/sharepoint/tenant/administration/theme_properties.py index f82bd8581..a8a2a0ecf 100644 --- a/office365/sharepoint/tenant/administration/theme_properties.py +++ b/office365/sharepoint/tenant/administration/theme_properties.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class ThemeProperties(BaseEntity): +class ThemeProperties(Entity): @property def entity_type_name(self): return "Microsoft.Online.SharePoint.TenantManagement.ThemeProperties" diff --git a/office365/sharepoint/tenant/administration/webs/templates/collection.py b/office365/sharepoint/tenant/administration/webs/templates/collection.py index 515ffa255..43d33ae5d 100644 --- a/office365/sharepoint/tenant/administration/webs/templates/collection.py +++ b/office365/sharepoint/tenant/administration/webs/templates/collection.py @@ -1,11 +1,11 @@ from office365.runtime.client_value_collection import ClientValueCollection -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.tenant.administration.webs.templates.template import ( SPOTenantWebTemplate, ) -class SPOTenantWebTemplateCollection(BaseEntity): +class SPOTenantWebTemplateCollection(Entity): @property def items(self): return self.properties.get("Items", ClientValueCollection(SPOTenantWebTemplate)) diff --git a/office365/sharepoint/tenant/apps/instance.py b/office365/sharepoint/tenant/apps/instance.py index 6b130dc0b..d06346738 100644 --- a/office365/sharepoint/tenant/apps/instance.py +++ b/office365/sharepoint/tenant/apps/instance.py @@ -1,5 +1,5 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class TenantAppInstance(BaseEntity): +class TenantAppInstance(Entity): """Represents an instance of a tenant-scoped app for a given host web.""" diff --git a/office365/sharepoint/tenant/apps/user_experience_state.py b/office365/sharepoint/tenant/apps/user_experience_state.py index 347592ba1..23474dada 100644 --- a/office365/sharepoint/tenant/apps/user_experience_state.py +++ b/office365/sharepoint/tenant/apps/user_experience_state.py @@ -1,5 +1,5 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class UserExperienceState(BaseEntity): +class UserExperienceState(Entity): """""" diff --git a/office365/sharepoint/tenant/apps/utility.py b/office365/sharepoint/tenant/apps/utility.py index 45d7f00b7..14669852f 100644 --- a/office365/sharepoint/tenant/apps/utility.py +++ b/office365/sharepoint/tenant/apps/utility.py @@ -1,5 +1,5 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class TenantAppUtility(BaseEntity): +class TenantAppUtility(Entity): pass diff --git a/office365/sharepoint/tenant/cdn_api.py b/office365/sharepoint/tenant/cdn_api.py index 3a3afd15a..ad198c5f4 100644 --- a/office365/sharepoint/tenant/cdn_api.py +++ b/office365/sharepoint/tenant/cdn_api.py @@ -1,8 +1,8 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class TenantCdnApi(BaseEntity): +class TenantCdnApi(Entity): def __init__(self, context): super(TenantCdnApi, self).__init__( context, ResourcePath("Microsoft.SharePoint.TenantCdn.TenantCdnApi") diff --git a/office365/sharepoint/tenant/management/externalusers/collection.py b/office365/sharepoint/tenant/management/externalusers/collection.py index 82b536dcc..7338d1a64 100644 --- a/office365/sharepoint/tenant/management/externalusers/collection.py +++ b/office365/sharepoint/tenant/management/externalusers/collection.py @@ -1,11 +1,11 @@ from office365.runtime.paths.service_operation import ServiceOperationPath -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.tenant.management.externalusers.external_user import ( ExternalUser, ) -class ExternalUserCollection(BaseEntityCollection): +class ExternalUserCollection(EntityCollection): def __init__(self, context, resource_path=None): super(ExternalUserCollection, self).__init__( context, ExternalUser, resource_path diff --git a/office365/sharepoint/tenant/management/externalusers/external_user.py b/office365/sharepoint/tenant/management/externalusers/external_user.py index ac24373c8..339f0a432 100644 --- a/office365/sharepoint/tenant/management/externalusers/external_user.py +++ b/office365/sharepoint/tenant/management/externalusers/external_user.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class ExternalUser(BaseEntity): +class ExternalUser(Entity): @property def entity_type_name(self): return "Microsoft.Online.SharePoint.TenantManagement.ExternalUser" diff --git a/office365/sharepoint/tenant/management/externalusers/results/get.py b/office365/sharepoint/tenant/management/externalusers/results/get.py index 503b83c86..7b6632aa5 100644 --- a/office365/sharepoint/tenant/management/externalusers/results/get.py +++ b/office365/sharepoint/tenant/management/externalusers/results/get.py @@ -1,11 +1,11 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.tenant.management.externalusers.collection import ( ExternalUserCollection, ) -class GetExternalUsersResults(BaseEntity): +class GetExternalUsersResults(Entity): @property def total_user_count(self): return self.properties.get("TotalUserCount", None) diff --git a/office365/sharepoint/tenant/management/externalusers/results/remove.py b/office365/sharepoint/tenant/management/externalusers/results/remove.py index 5fe46eb4c..d7032e07c 100644 --- a/office365/sharepoint/tenant/management/externalusers/results/remove.py +++ b/office365/sharepoint/tenant/management/externalusers/results/remove.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class RemoveExternalUsersResults(BaseEntity): +class RemoveExternalUsersResults(Entity): @property def entity_type_name(self): return "Microsoft.Online.SharePoint.TenantManagement.RemoveExternalUsersResults" diff --git a/office365/sharepoint/tenant/management/externalusers/results/session_revocation.py b/office365/sharepoint/tenant/management/externalusers/results/session_revocation.py index 34f531b4f..433a1d0ba 100644 --- a/office365/sharepoint/tenant/management/externalusers/results/session_revocation.py +++ b/office365/sharepoint/tenant/management/externalusers/results/session_revocation.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SPOUserSessionRevocationResult(BaseEntity): +class SPOUserSessionRevocationResult(Entity): @property def entity_type_name(self): return "Microsoft.Online.SharePoint.TenantManagement.SPOUserSessionRevocationResult" diff --git a/office365/sharepoint/tenant/management/office365_tenant.py b/office365/sharepoint/tenant/management/office365_tenant.py index 43d5195b8..84b097650 100644 --- a/office365/sharepoint/tenant/management/office365_tenant.py +++ b/office365/sharepoint/tenant/management/office365_tenant.py @@ -3,7 +3,7 @@ from office365.runtime.client_value_collection import ClientValueCollection from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.principal.users.user import User from office365.sharepoint.tenant.administration.siteinfo_for_site_picker import ( SiteInfoForSitePicker, @@ -20,7 +20,7 @@ ) -class Office365Tenant(BaseEntity): +class Office365Tenant(Entity): """Represents a SharePoint Online tenant.""" def __init__(self, context): diff --git a/office365/sharepoint/tenant/settings.py b/office365/sharepoint/tenant/settings.py index cac763571..56fd552f0 100644 --- a/office365/sharepoint/tenant/settings.py +++ b/office365/sharepoint/tenant/settings.py @@ -1,9 +1,9 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class TenantSettings(BaseEntity): +class TenantSettings(Entity): """Specifies the tenant properties.""" def clear_corporate_catalog(self): diff --git a/office365/sharepoint/translation/job.py b/office365/sharepoint/translation/job.py index af15bf539..1a2378003 100644 --- a/office365/sharepoint/translation/job.py +++ b/office365/sharepoint/translation/job.py @@ -1,10 +1,10 @@ from office365.runtime.client_result import ClientResult from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class TranslationJob(BaseEntity): +class TranslationJob(Entity): """ The TranslationJob type is used to create new translation jobs. """ diff --git a/office365/sharepoint/translation/job_status.py b/office365/sharepoint/translation/job_status.py index 3c6b25502..b09762a30 100644 --- a/office365/sharepoint/translation/job_status.py +++ b/office365/sharepoint/translation/job_status.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class TranslationJobStatus(BaseEntity): +class TranslationJobStatus(Entity): """The TranslationJobStatus type is used to get information about previously submitted translation jobs and the translation items associated with them. The type provides methods to retrieve TranslationJobInfo (section 3.1.5.4) and TranslationItemInfo (section 3.1.5.2) objects. diff --git a/office365/sharepoint/translation/notification_recipient_users.py b/office365/sharepoint/translation/notification_recipient_users.py index 10ecc9ba3..3fe4ec10b 100644 --- a/office365/sharepoint/translation/notification_recipient_users.py +++ b/office365/sharepoint/translation/notification_recipient_users.py @@ -1,8 +1,8 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class TranslationNotificationRecipientUsers(BaseEntity): +class TranslationNotificationRecipientUsers(Entity): @property def language_code(self): return self.properties.get("LanguageCode", None) diff --git a/office365/sharepoint/translation/status_collection.py b/office365/sharepoint/translation/status_collection.py index 0b6e4d4bb..1a68f2ad1 100644 --- a/office365/sharepoint/translation/status_collection.py +++ b/office365/sharepoint/translation/status_collection.py @@ -1,14 +1,14 @@ from office365.runtime.client_value_collection import ClientValueCollection from office365.runtime.queries.service_operation import ServiceOperationQuery from office365.runtime.types.collections import StringCollection -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.translation.status import TranslationStatus from office365.sharepoint.translation.status_set_request import ( TranslationStatusSetRequest, ) -class TranslationStatusCollection(BaseEntity): +class TranslationStatusCollection(Entity): def __init__(self, context, resource_path=None): super(TranslationStatusCollection, self).__init__(context, resource_path) diff --git a/office365/sharepoint/translation/sync_translator.py b/office365/sharepoint/translation/sync_translator.py index f6cc5ce4c..d7fff47ac 100644 --- a/office365/sharepoint/translation/sync_translator.py +++ b/office365/sharepoint/translation/sync_translator.py @@ -1,11 +1,11 @@ from office365.runtime.client_result import ClientResult from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.translation.item_info import TranslationItemInfo -class SyncTranslator(BaseEntity): +class SyncTranslator(Entity): """ The SyncTranslator type is used to submit immediate translation jobs to the protocol server. diff --git a/office365/sharepoint/translation/user_resource.py b/office365/sharepoint/translation/user_resource.py index eb3425c95..fc32a6fdd 100644 --- a/office365/sharepoint/translation/user_resource.py +++ b/office365/sharepoint/translation/user_resource.py @@ -1,11 +1,11 @@ from office365.runtime.client_result import ClientResult from office365.runtime.client_value_collection import ClientValueCollection from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.translation.resource_entry import SPResourceEntry -class UserResource(BaseEntity): +class UserResource(Entity): """An object representing user-defined localizable resources.""" def get_value_for_ui_culture(self, culture_name): diff --git a/office365/sharepoint/translation/variations_timer_job.py b/office365/sharepoint/translation/variations_timer_job.py index fa23f89d8..50e84d75d 100644 --- a/office365/sharepoint/translation/variations_timer_job.py +++ b/office365/sharepoint/translation/variations_timer_job.py @@ -1,9 +1,9 @@ from office365.runtime.client_value_collection import ClientValueCollection from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class VariationsTranslationTimerJob(BaseEntity): +class VariationsTranslationTimerJob(Entity): """ The VariationsTranslationTimerJob type provides methods to drive translation for list items in a variation label. """ diff --git a/office365/sharepoint/types/property_values.py b/office365/sharepoint/types/property_values.py index 76afaab88..dbf706ee1 100644 --- a/office365/sharepoint/types/property_values.py +++ b/office365/sharepoint/types/property_values.py @@ -1,5 +1,5 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class PropertyValues(BaseEntity): +class PropertyValues(Entity): """Contains the collection of name/value pairs of all the CSOM expando fields.""" diff --git a/office365/sharepoint/ui/applicationpages/peoplepicker/web_service_interface.py b/office365/sharepoint/ui/applicationpages/peoplepicker/web_service_interface.py index ad0b1c0a7..90592164d 100644 --- a/office365/sharepoint/ui/applicationpages/peoplepicker/web_service_interface.py +++ b/office365/sharepoint/ui/applicationpages/peoplepicker/web_service_interface.py @@ -1,6 +1,6 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.principal.type import PrincipalType from office365.sharepoint.ui.applicationpages.peoplepicker.entity_information import ( PickerEntityInformation, @@ -13,7 +13,7 @@ ) -class ClientPeoplePickerWebServiceInterface(BaseEntity): +class ClientPeoplePickerWebServiceInterface(Entity): """Specifies an interface that can be used to query principals.""" @staticmethod diff --git a/office365/sharepoint/usercustomactions/action.py b/office365/sharepoint/usercustomactions/action.py index dfab33cbb..815c53423 100644 --- a/office365/sharepoint/usercustomactions/action.py +++ b/office365/sharepoint/usercustomactions/action.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class UserCustomAction(BaseEntity): +class UserCustomAction(Entity): """Represents a custom action associated with a SharePoint list, Web site, or subsite.""" @property diff --git a/office365/sharepoint/usercustomactions/collection.py b/office365/sharepoint/usercustomactions/collection.py index ba2c08b69..132198396 100644 --- a/office365/sharepoint/usercustomactions/collection.py +++ b/office365/sharepoint/usercustomactions/collection.py @@ -1,9 +1,9 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.usercustomactions.action import UserCustomAction -class UserCustomActionCollection(BaseEntityCollection): +class UserCustomActionCollection(EntityCollection): def __init__(self, context, resource_path=None): """Specifies a collection of custom actions.""" super(UserCustomActionCollection, self).__init__( diff --git a/office365/sharepoint/userprofiles/followed_content.py b/office365/sharepoint/userprofiles/followed_content.py index 788585991..636526843 100644 --- a/office365/sharepoint/userprofiles/followed_content.py +++ b/office365/sharepoint/userprofiles/followed_content.py @@ -1,10 +1,10 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.userprofiles.follow_result import FollowResult -class FollowedContent(BaseEntity): +class FollowedContent(Entity): """The FollowedContent class provides access to followed content items.""" def follow_item(self, item): diff --git a/office365/sharepoint/userprofiles/hash_tag.py b/office365/sharepoint/userprofiles/hash_tag.py index 48fc96358..ba70ddd44 100644 --- a/office365/sharepoint/userprofiles/hash_tag.py +++ b/office365/sharepoint/userprofiles/hash_tag.py @@ -1,6 +1,6 @@ from office365.runtime.client_value import ClientValue from office365.runtime.client_value_collection import ClientValueCollection -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity class HashTag(ClientValue): @@ -19,7 +19,7 @@ def entity_type_name(self): return "SP.UserProfiles.HashTag" -class HashTagCollection(BaseEntity): +class HashTagCollection(Entity): """The HashTagCollection class specifies a collection of HashTags. For information about the HashTag type, see section 3.1.5.55""" diff --git a/office365/sharepoint/userprofiles/my_site_links.py b/office365/sharepoint/userprofiles/my_site_links.py index 049e6103c..8cce10c1b 100644 --- a/office365/sharepoint/userprofiles/my_site_links.py +++ b/office365/sharepoint/userprofiles/my_site_links.py @@ -1,8 +1,8 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class MySiteLinks(BaseEntity): +class MySiteLinks(Entity): """The MySiteLinks object provides links for a user’s personal site.""" @staticmethod diff --git a/office365/sharepoint/userprofiles/mysite/dismiss_status_text.py b/office365/sharepoint/userprofiles/mysite/dismiss_status_text.py index f462bb1f9..188706915 100644 --- a/office365/sharepoint/userprofiles/mysite/dismiss_status_text.py +++ b/office365/sharepoint/userprofiles/mysite/dismiss_status_text.py @@ -1,8 +1,8 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class MySiteDismissStatusText(BaseEntity): +class MySiteDismissStatusText(Entity): """Provides methods to dismiss status text for the personal online document library page.""" @staticmethod diff --git a/office365/sharepoint/userprofiles/people_manager.py b/office365/sharepoint/userprofiles/people_manager.py index ee64b5f5b..a0b0948e9 100644 --- a/office365/sharepoint/userprofiles/people_manager.py +++ b/office365/sharepoint/userprofiles/people_manager.py @@ -2,8 +2,8 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery from office365.runtime.types.collections import StringCollection -from office365.sharepoint.base_entity import BaseEntity -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity import Entity +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.principal.users.user import User from office365.sharepoint.userprofiles.hash_tag import HashTagCollection from office365.sharepoint.userprofiles.person_properties import PersonProperties @@ -27,7 +27,7 @@ def _user_loaded(): action(user_or_name) -class PeopleManager(BaseEntity): +class PeopleManager(Entity): """Provides methods for operations related to people.""" def __init__(self, context): @@ -82,7 +82,7 @@ def get_followers_for(self, account_name): :param str account_name: Account name of the specified user. :return: """ - return_type = BaseEntityCollection(self.context, PersonProperties) + return_type = EntityCollection(self.context, PersonProperties) params = {"accountName": account_name} qry = ServiceOperationQuery( self, "GetFollowersFor", params, None, None, return_type @@ -211,9 +211,8 @@ def get_people_followed_by(self, account_name): user cannot be found. :param str account_name: Account name of the specified user. - :return: BaseEntityCollection """ - return_type = BaseEntityCollection(self.context, PersonProperties) + return_type = EntityCollection(self.context, PersonProperties) params = {"accountName": account_name} qry = ServiceOperationQuery( self, "GetPeopleFollowedBy", params, None, None, return_type @@ -225,7 +224,7 @@ def get_my_followers(self): """ This method returns a list of PersonProperties objects for the people who are following the current user. """ - return_type = BaseEntityCollection(self.context, PersonProperties) + return_type = EntityCollection(self.context, PersonProperties) qry = ServiceOperationQuery( self, "GetMyFollowers", None, None, None, return_type ) diff --git a/office365/sharepoint/userprofiles/person_properties.py b/office365/sharepoint/userprofiles/person_properties.py index 96998bc23..63993c7b3 100644 --- a/office365/sharepoint/userprofiles/person_properties.py +++ b/office365/sharepoint/userprofiles/person_properties.py @@ -1,8 +1,8 @@ from office365.runtime.types.collections import StringCollection -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class PersonProperties(BaseEntity): +class PersonProperties(Entity): """ The PersonProperties class contains the data about people and is returned by PeopleManager methods (see section 3.1.5.58). diff --git a/office365/sharepoint/userprofiles/personal_cache.py b/office365/sharepoint/userprofiles/personal_cache.py index 241d9d9bf..dcaf6a7af 100644 --- a/office365/sharepoint/userprofiles/personal_cache.py +++ b/office365/sharepoint/userprofiles/personal_cache.py @@ -1,9 +1,9 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class PersonalCache(BaseEntity): +class PersonalCache(Entity): """Per user cache of key/value pairs organized by folders. Personal cache MAY be used for optimizing initial load performance of the protocol client, if obtaining initial set of data from personal cache is faster that requesting the data from the server.""" diff --git a/office365/sharepoint/userprofiles/profile_image_store.py b/office365/sharepoint/userprofiles/profile_image_store.py index 1664fcd1e..cd2c33e99 100644 --- a/office365/sharepoint/userprofiles/profile_image_store.py +++ b/office365/sharepoint/userprofiles/profile_image_store.py @@ -2,10 +2,10 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery from office365.runtime.types.collections import StringCollection -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class ProfileImageStore(BaseEntity): +class ProfileImageStore(Entity): """The ProfileImageStore class specifies the user profile and service context.""" def __init__(self, context): diff --git a/office365/sharepoint/userprofiles/promoted_sites.py b/office365/sharepoint/userprofiles/promoted_sites.py index 3d2a95426..041ccb7c4 100644 --- a/office365/sharepoint/userprofiles/promoted_sites.py +++ b/office365/sharepoint/userprofiles/promoted_sites.py @@ -1,11 +1,11 @@ from office365.runtime.client_result import ClientResult from office365.runtime.client_value_collection import ClientValueCollection from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.webparts.tile_data import TileData -class PromotedSites(BaseEntity): +class PromotedSites(Entity): """ The PromotedSites object provides access to a collection of site links that are visible to all users. """ diff --git a/office365/sharepoint/userprofiles/properties_for_user.py b/office365/sharepoint/userprofiles/properties_for_user.py index d75662b9d..17462fb7c 100644 --- a/office365/sharepoint/userprofiles/properties_for_user.py +++ b/office365/sharepoint/userprofiles/properties_for_user.py @@ -2,10 +2,10 @@ from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.service_operation import ServiceOperationQuery from office365.runtime.types.collections import StringCollection -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class UserProfilePropertiesForUser(BaseEntity): +class UserProfilePropertiesForUser(Entity): """The UserProfilePropertiesForUser class represents a set of user profile properties for a user.""" def get_property_names(self): diff --git a/office365/sharepoint/userprofiles/sharedwithme/document.py b/office365/sharepoint/userprofiles/sharedwithme/document.py index ec2eb6fa3..2219ac815 100644 --- a/office365/sharepoint/userprofiles/sharedwithme/document.py +++ b/office365/sharepoint/userprofiles/sharedwithme/document.py @@ -1,13 +1,13 @@ from datetime import datetime from office365.runtime.client_value_collection import ClientValueCollection -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.userprofiles.sharedwithme.document_user import ( SharedWithMeDocumentUser, ) -class SharedWithMeDocument(BaseEntity): +class SharedWithMeDocument(Entity): """Represents a shared document.""" @property diff --git a/office365/sharepoint/userprofiles/sharedwithme/item_collection.py b/office365/sharepoint/userprofiles/sharedwithme/item_collection.py index c79c92e4b..a8422bb9e 100644 --- a/office365/sharepoint/userprofiles/sharedwithme/item_collection.py +++ b/office365/sharepoint/userprofiles/sharedwithme/item_collection.py @@ -1,9 +1,9 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class SharedWithMeItemCollection(BaseEntity): +class SharedWithMeItemCollection(Entity): """""" @staticmethod diff --git a/office365/sharepoint/userprofiles/sharedwithme/items.py b/office365/sharepoint/userprofiles/sharedwithme/items.py index e92d0b5d2..ad61115fd 100644 --- a/office365/sharepoint/userprofiles/sharedwithme/items.py +++ b/office365/sharepoint/userprofiles/sharedwithme/items.py @@ -1,10 +1,10 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity import Entity +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.userprofiles.sharedwithme.document import SharedWithMeDocument -class SharedWithMeItems(BaseEntity): +class SharedWithMeItems(Entity): """""" @staticmethod @@ -13,7 +13,7 @@ def shared_with_me(context): :param office365.sharepoint.client_context.ClientContext context: Client context """ binding_type = SharedWithMeItems(context) - return_type = BaseEntityCollection(context, SharedWithMeDocument) + return_type = EntityCollection(context, SharedWithMeDocument) qry = ServiceOperationQuery( binding_type, "SharedWithMe", return_type=return_type, is_static=True ) diff --git a/office365/sharepoint/userprofiles/user_profile.py b/office365/sharepoint/userprofiles/user_profile.py index 323e7e92a..75cc96f44 100644 --- a/office365/sharepoint/userprofiles/user_profile.py +++ b/office365/sharepoint/userprofiles/user_profile.py @@ -1,12 +1,12 @@ from office365.runtime.client_result import ClientResult from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.sites.site import Site from office365.sharepoint.userprofiles.followed_content import FollowedContent -class UserProfile(BaseEntity): +class UserProfile(Entity): """The UserProfile class stores the profile of the individual user, which includes properties such as the user's account name, preferred name, and email address.""" diff --git a/office365/sharepoint/utilities/move_copy_util.py b/office365/sharepoint/utilities/move_copy_util.py index f0b37d90a..776b554ff 100644 --- a/office365/sharepoint/utilities/move_copy_util.py +++ b/office365/sharepoint/utilities/move_copy_util.py @@ -2,11 +2,11 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.types.resource_path import ResourcePath as SPResPath -class MoveCopyUtil(BaseEntity): +class MoveCopyUtil(Entity): """A container class for static move/copy methods.""" @staticmethod diff --git a/office365/sharepoint/utilities/upload_status.py b/office365/sharepoint/utilities/upload_status.py index 32b6c701f..7fce7340c 100644 --- a/office365/sharepoint/utilities/upload_status.py +++ b/office365/sharepoint/utilities/upload_status.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class UploadStatus(BaseEntity): +class UploadStatus(Entity): """The status of a chunk session upload.""" @property diff --git a/office365/sharepoint/utilities/utility.py b/office365/sharepoint/utilities/utility.py index d5f838ce8..664b5b890 100644 --- a/office365/sharepoint/utilities/utility.py +++ b/office365/sharepoint/utilities/utility.py @@ -3,13 +3,13 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery from office365.runtime.types.collections import StringCollection -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.files.file import File from office365.sharepoint.types.resource_path import ResourcePath as SPResPath from office365.sharepoint.utilities.principal_info import PrincipalInfo -class Utility(BaseEntity): +class Utility(Entity): """ Provides tools for converting date and time formats, for obtaining information from user names, for modifying access to sites, and for various other tasks in managing deployment. diff --git a/office365/sharepoint/views/collection.py b/office365/sharepoint/views/collection.py index 5b01fd9f3..138211375 100644 --- a/office365/sharepoint/views/collection.py +++ b/office365/sharepoint/views/collection.py @@ -1,10 +1,10 @@ from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.views.view import View -class ViewCollection(BaseEntityCollection): +class ViewCollection(EntityCollection): """Represents a collection of View resources.""" def __init__(self, context, resource_path=None, parent_list=None): diff --git a/office365/sharepoint/views/field_collection.py b/office365/sharepoint/views/field_collection.py index 977abd20e..829e59332 100644 --- a/office365/sharepoint/views/field_collection.py +++ b/office365/sharepoint/views/field_collection.py @@ -1,8 +1,8 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class ViewFieldCollection(BaseEntity): +class ViewFieldCollection(Entity): """Represents a collection of Field resources.""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/views/view.py b/office365/sharepoint/views/view.py index ae1b377b3..e0a77eadb 100644 --- a/office365/sharepoint/views/view.py +++ b/office365/sharepoint/views/view.py @@ -1,8 +1,8 @@ from office365.runtime.client_result import ClientResult from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity from office365.sharepoint.contenttypes.content_type_id import ContentTypeId +from office365.sharepoint.entity import Entity from office365.sharepoint.listitems.caml.query import CamlQuery from office365.sharepoint.listitems.collection import ListItemCollection from office365.sharepoint.types.resource_path import ResourcePath as SPResPath @@ -10,7 +10,7 @@ from office365.sharepoint.views.visualization import Visualization -class View(BaseEntity): +class View(Entity): """Specifies a List View.""" def __init__(self, context, resource_path=None, parent_list=None): diff --git a/office365/sharepoint/viva/app_configuration.py b/office365/sharepoint/viva/app_configuration.py index be1992a5c..746a4a271 100644 --- a/office365/sharepoint/viva/app_configuration.py +++ b/office365/sharepoint/viva/app_configuration.py @@ -1,5 +1,5 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class AppConfiguration(BaseEntity): +class AppConfiguration(Entity): pass diff --git a/office365/sharepoint/viva/employee_engagement.py b/office365/sharepoint/viva/employee_engagement.py index b8aa004bf..6973cf1c9 100644 --- a/office365/sharepoint/viva/employee_engagement.py +++ b/office365/sharepoint/viva/employee_engagement.py @@ -2,12 +2,12 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.function import FunctionQuery from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.viva.app_configuration import AppConfiguration from office365.sharepoint.viva.home import VivaHome -class EmployeeEngagement(BaseEntity): +class EmployeeEngagement(Entity): def __init__(self, context): super(EmployeeEngagement, self).__init__( context, ResourcePath("SP.EmployeeEngagement") diff --git a/office365/sharepoint/viva/employee_experience_controller.py b/office365/sharepoint/viva/employee_experience_controller.py index 5a6dd0d36..c68c81bb4 100644 --- a/office365/sharepoint/viva/employee_experience_controller.py +++ b/office365/sharepoint/viva/employee_experience_controller.py @@ -1,5 +1,5 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class EmployeeExperienceController(BaseEntity): +class EmployeeExperienceController(Entity): pass diff --git a/office365/sharepoint/viva/home.py b/office365/sharepoint/viva/home.py index 825cf52b4..7d5ebc390 100644 --- a/office365/sharepoint/viva/home.py +++ b/office365/sharepoint/viva/home.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class VivaHome(BaseEntity): +class VivaHome(Entity): @property def entity_type_name(self): return "Microsoft.SharePoint.EmployeeEngagement.VivaHome" diff --git a/office365/sharepoint/viva/site_manager.py b/office365/sharepoint/viva/site_manager.py index 710b626d0..46e96ce09 100644 --- a/office365/sharepoint/viva/site_manager.py +++ b/office365/sharepoint/viva/site_manager.py @@ -1,8 +1,8 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class VivaSiteManager(BaseEntity): +class VivaSiteManager(Entity): """""" def __init__(self, content, resource_path=None): diff --git a/office365/sharepoint/webhooks/subscription.py b/office365/sharepoint/webhooks/subscription.py index e59426f31..88ed8da6f 100644 --- a/office365/sharepoint/webhooks/subscription.py +++ b/office365/sharepoint/webhooks/subscription.py @@ -1,10 +1,10 @@ from datetime import datetime from office365.runtime.paths.service_operation import ServiceOperationPath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class Subscription(BaseEntity): +class Subscription(Entity): """A subscription for receiving notifications at a specified endpoint.""" @property diff --git a/office365/sharepoint/webhooks/subscription_collection.py b/office365/sharepoint/webhooks/subscription_collection.py index 8cb8ca3e3..f2477411b 100644 --- a/office365/sharepoint/webhooks/subscription_collection.py +++ b/office365/sharepoint/webhooks/subscription_collection.py @@ -1,13 +1,13 @@ from office365.runtime.paths.service_operation import ServiceOperationPath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.webhooks.subscription import Subscription from office365.sharepoint.webhooks.subscription_information import ( SubscriptionInformation, ) -class SubscriptionCollection(BaseEntityCollection): +class SubscriptionCollection(EntityCollection): """Represents a collection of Subscription (WebHook) resources.""" def __init__(self, context, resource_path=None, parent=None): diff --git a/office365/sharepoint/webparts/client/collection.py b/office365/sharepoint/webparts/client/collection.py index ecd6c0376..36744626d 100644 --- a/office365/sharepoint/webparts/client/collection.py +++ b/office365/sharepoint/webparts/client/collection.py @@ -1,9 +1,9 @@ from office365.runtime.paths.service_operation import ServiceOperationPath -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.webparts.client.webpart import ClientWebPart -class ClientWebPartCollection(BaseEntityCollection): +class ClientWebPartCollection(EntityCollection): """Collection of ClientWebPart representations. It includes all ClientWebParts installed in the SP.Web.""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/webparts/client/webpart.py b/office365/sharepoint/webparts/client/webpart.py index 9886e3077..20b6ed159 100644 --- a/office365/sharepoint/webparts/client/webpart.py +++ b/office365/sharepoint/webparts/client/webpart.py @@ -1,9 +1,9 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class ClientWebPart(BaseEntity): +class ClientWebPart(Entity): """Representation of a ClientWebPart. It provides with ClientWebPart metadata and methods to render it.""" def render(self, properties=None): diff --git a/office365/sharepoint/webparts/definition.py b/office365/sharepoint/webparts/definition.py index 9b5268d11..b5ba585a0 100644 --- a/office365/sharepoint/webparts/definition.py +++ b/office365/sharepoint/webparts/definition.py @@ -1,10 +1,10 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.webparts.webpart import WebPart -class WebPartDefinition(BaseEntity): +class WebPartDefinition(Entity): """Represents a Web Part on a Web Part Page. Provides operations for moving, deleting, and changing the state of the Web Part.""" diff --git a/office365/sharepoint/webparts/definition_collection.py b/office365/sharepoint/webparts/definition_collection.py index 4df92b3ca..3fe39b0e9 100644 --- a/office365/sharepoint/webparts/definition_collection.py +++ b/office365/sharepoint/webparts/definition_collection.py @@ -1,9 +1,9 @@ from office365.runtime.paths.service_operation import ServiceOperationPath -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.webparts.definition import WebPartDefinition -class WebPartDefinitionCollection(BaseEntityCollection): +class WebPartDefinitionCollection(EntityCollection): """Implements a collection of Web Part definition objects""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/webparts/limited_manager.py b/office365/sharepoint/webparts/limited_manager.py index 1539435c7..5ef3b0ac8 100644 --- a/office365/sharepoint/webparts/limited_manager.py +++ b/office365/sharepoint/webparts/limited_manager.py @@ -1,11 +1,11 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.webparts.definition_collection import ( WebPartDefinitionCollection, ) -class LimitedWebPartManager(BaseEntity): +class LimitedWebPartManager(Entity): """Provides operations to access and modify the existing Web Parts on a Web Part Page, and add new ones to the Web Part Page.""" diff --git a/office365/sharepoint/webparts/webpart.py b/office365/sharepoint/webparts/webpart.py index 601666c63..152f3187d 100644 --- a/office365/sharepoint/webparts/webpart.py +++ b/office365/sharepoint/webparts/webpart.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class WebPart(BaseEntity): +class WebPart(Entity): """ A reusable component that contains or generates web-based content such as XML, HTML, and scripting code. It has a standard property schema and displays that content in a cohesive unit on a webpage. See also Web Parts Page diff --git a/office365/sharepoint/webs/collection.py b/office365/sharepoint/webs/collection.py index 3661d94be..4f9ebec14 100644 --- a/office365/sharepoint/webs/collection.py +++ b/office365/sharepoint/webs/collection.py @@ -1,9 +1,9 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.webs.web import Web -class WebCollection(BaseEntityCollection): +class WebCollection(EntityCollection): """Web collection""" def __init__(self, context, resource_path=None, parent_web=None): diff --git a/office365/sharepoint/webs/information.py b/office365/sharepoint/webs/information.py index 88b35ab68..2517d6c8a 100644 --- a/office365/sharepoint/webs/information.py +++ b/office365/sharepoint/webs/information.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class WebInformation(BaseEntity): +class WebInformation(Entity): """Specifies metadata about a site""" pass diff --git a/office365/sharepoint/webs/information_collection.py b/office365/sharepoint/webs/information_collection.py index ad4d778df..0d3146ec1 100644 --- a/office365/sharepoint/webs/information_collection.py +++ b/office365/sharepoint/webs/information_collection.py @@ -1,9 +1,9 @@ from office365.runtime.paths.service_operation import ServiceOperationPath -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.webs.information import WebInformation -class WebInformationCollection(BaseEntityCollection): +class WebInformationCollection(EntityCollection): """Specifies a collection of objects containing metadata about a site""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/webs/modernize_homepage_result.py b/office365/sharepoint/webs/modernize_homepage_result.py index caadcbfc2..2e866b52e 100644 --- a/office365/sharepoint/webs/modernize_homepage_result.py +++ b/office365/sharepoint/webs/modernize_homepage_result.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class ModernizeHomepageResult(BaseEntity): +class ModernizeHomepageResult(Entity): """""" @property diff --git a/office365/sharepoint/webs/multilingual_settings.py b/office365/sharepoint/webs/multilingual_settings.py index f9a93a803..41b70cf10 100644 --- a/office365/sharepoint/webs/multilingual_settings.py +++ b/office365/sharepoint/webs/multilingual_settings.py @@ -1,7 +1,7 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity import Entity +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.translation.notification_recipient_set_request import ( TranslationNotificationRecipientSetRequest, ) @@ -10,7 +10,7 @@ ) -class MultilingualSettings(BaseEntity): +class MultilingualSettings(Entity): def set_notification_recipients(self, notification_recipients): """ :param list notification_recipients: @@ -24,7 +24,7 @@ def set_notification_recipients(self, notification_recipients): def recipients(self): return self.properties.get( "Recipients", - BaseEntityCollection( + EntityCollection( self.context, TranslationNotificationRecipientUsers, ResourcePath("Recipients", self.resource_path), diff --git a/office365/sharepoint/webs/regional_settings.py b/office365/sharepoint/webs/regional_settings.py index 355b020e0..a1bee47ad 100644 --- a/office365/sharepoint/webs/regional_settings.py +++ b/office365/sharepoint/webs/regional_settings.py @@ -1,10 +1,10 @@ from office365.runtime.paths.resource_path import ResourcePath -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity from office365.sharepoint.sites.language_collection import LanguageCollection from office365.sharepoint.webs.time_zone import TimeZone, TimeZoneCollection -class RegionalSettings(BaseEntity): +class RegionalSettings(Entity): """Represents regional settings that are used on the server that is running SharePoint Server.""" @property diff --git a/office365/sharepoint/webs/template.py b/office365/sharepoint/webs/template.py index 3a438c105..24388e6f0 100644 --- a/office365/sharepoint/webs/template.py +++ b/office365/sharepoint/webs/template.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class WebTemplate(BaseEntity): +class WebTemplate(Entity): """Specifies a site definition or a site template that is used to instantiate a site.""" def __repr__(self): diff --git a/office365/sharepoint/webs/template_collection.py b/office365/sharepoint/webs/template_collection.py index d59fc7291..1abc372b1 100644 --- a/office365/sharepoint/webs/template_collection.py +++ b/office365/sharepoint/webs/template_collection.py @@ -1,9 +1,9 @@ from office365.runtime.paths.service_operation import ServiceOperationPath -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.webs.template import WebTemplate -class WebTemplateCollection(BaseEntityCollection): +class WebTemplateCollection(EntityCollection): """Specifies a collection of site templates.""" def __init__(self, context, resource_path=None, parent=None): diff --git a/office365/sharepoint/webs/theme_info.py b/office365/sharepoint/webs/theme_info.py index 00d4c3ae2..894459b7d 100644 --- a/office365/sharepoint/webs/theme_info.py +++ b/office365/sharepoint/webs/theme_info.py @@ -1,9 +1,9 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class ThemeInfo(BaseEntity): +class ThemeInfo(Entity): """Specifies a theme for a site""" def get_theme_font_by_name(self, name, lcid): diff --git a/office365/sharepoint/webs/time_zone.py b/office365/sharepoint/webs/time_zone.py index e67582985..85b1852f3 100644 --- a/office365/sharepoint/webs/time_zone.py +++ b/office365/sharepoint/webs/time_zone.py @@ -1,11 +1,11 @@ from office365.runtime.client_result import ClientResult from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity import Entity +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.webs.time_zone_information import TimeZoneInformation -class TimeZone(BaseEntity): +class TimeZone(Entity): """Represents the time zone setting that is implemented on a SharePoint Web site.""" def local_time_to_utc(self, date): @@ -44,7 +44,7 @@ def information(self): return self.properties.get("Information", TimeZoneInformation()) -class TimeZoneCollection(BaseEntityCollection): +class TimeZoneCollection(EntityCollection): """TimeZone collection""" def __init__(self, context, resource_path=None): diff --git a/office365/sharepoint/webs/web.py b/office365/sharepoint/webs/web.py index 0faba3d1c..05146ef0d 100644 --- a/office365/sharepoint/webs/web.py +++ b/office365/sharepoint/webs/web.py @@ -5,7 +5,6 @@ from office365.runtime.client_value_collection import ClientValueCollection from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.paths.service_operation import ServiceOperationPath -from office365.runtime.queries.function import FunctionQuery from office365.runtime.queries.service_operation import ServiceOperationQuery from office365.runtime.types.collections import StringCollection from office365.sharepoint.activities.entity import SPActivityEntity @@ -14,7 +13,6 @@ from office365.sharepoint.authentication.acs_service_principal_info import ( SPACSServicePrincipalInfo, ) -from office365.sharepoint.base_entity_collection import BaseEntityCollection from office365.sharepoint.businessdata.app_bdc_catalog import AppBdcCatalog from office365.sharepoint.changes.collection import ChangeCollection from office365.sharepoint.clientsidecomponent.hostedapps.manager import ( @@ -28,6 +26,7 @@ ) from office365.sharepoint.clientsidecomponent.storage_entity import StorageEntity from office365.sharepoint.contenttypes.collection import ContentTypeCollection +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.eventreceivers.definition_collection import ( EventReceiverDefinitionCollection, ) @@ -410,7 +409,7 @@ def get_group_based_environment(self): def get_acs_service_principals(self, app_ids=None): """ List service principals - :param list[str] appIds: + :param list[str] app_ids: """ payload = {"appIds": app_ids} return_type = ClientResult( @@ -1794,7 +1793,7 @@ def assign_document_id(self, site_prefix, enabled=True): def activities(self): return self.properties.get( "Activities", - BaseEntityCollection( + EntityCollection( self.context, SPActivityEntity, ResourcePath("Activities", self.resource_path), @@ -1975,7 +1974,7 @@ def onedrive_shared_items(self): """""" return self.properties.get( "OneDriveSharedItems", - BaseEntityCollection( + EntityCollection( self.context, SharedDocumentInfo, ResourcePath("OneDriveSharedItems", self.resource_path), diff --git a/office365/sharepoint/workflow/association.py b/office365/sharepoint/workflow/association.py index 3c5a7bdb0..4abb82e29 100644 --- a/office365/sharepoint/workflow/association.py +++ b/office365/sharepoint/workflow/association.py @@ -1,5 +1,5 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class WorkflowAssociation(BaseEntity): +class WorkflowAssociation(Entity): """Represents the association of a workflow template with a specific list or content type""" diff --git a/office365/sharepoint/workflow/template.py b/office365/sharepoint/workflow/template.py index 98564e0d8..80f9374b5 100644 --- a/office365/sharepoint/workflow/template.py +++ b/office365/sharepoint/workflow/template.py @@ -1,5 +1,5 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class WorkflowTemplate(BaseEntity): +class WorkflowTemplate(Entity): """Represents a workflow template currently deployed on the site""" diff --git a/office365/sharepoint/workflowservices/instance.py b/office365/sharepoint/workflowservices/instance.py index c6d56b8f1..bdd6d439c 100644 --- a/office365/sharepoint/workflowservices/instance.py +++ b/office365/sharepoint/workflowservices/instance.py @@ -1,7 +1,7 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class WorkflowInstance(BaseEntity): +class WorkflowInstance(Entity): """Represents a workflow instance.""" @property diff --git a/office365/sharepoint/workflowservices/instance_service.py b/office365/sharepoint/workflowservices/instance_service.py index 0439b86fc..35f6f4d55 100644 --- a/office365/sharepoint/workflowservices/instance_service.py +++ b/office365/sharepoint/workflowservices/instance_service.py @@ -1,17 +1,17 @@ from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity -from office365.sharepoint.base_entity_collection import BaseEntityCollection +from office365.sharepoint.entity import Entity +from office365.sharepoint.entity_collection import EntityCollection from office365.sharepoint.workflowservices.instance import WorkflowInstance -class WorkflowInstanceService(BaseEntity): +class WorkflowInstanceService(Entity): """Manages and reads workflow instances from the workflow host.""" def enumerate_instances_for_site(self): """ Returns the site workflow instances for the current site. """ - return_type = BaseEntityCollection(self.context, WorkflowInstance) + return_type = EntityCollection(self.context, WorkflowInstance) qry = ServiceOperationQuery( self, "EnumerateInstancesForSite", None, None, None, return_type ) diff --git a/office365/sharepoint/workflowservices/manager.py b/office365/sharepoint/workflowservices/manager.py index c355da54c..99103ddac 100644 --- a/office365/sharepoint/workflowservices/manager.py +++ b/office365/sharepoint/workflowservices/manager.py @@ -1,9 +1,9 @@ from office365.runtime.paths.resource_path import ResourcePath from office365.runtime.queries.service_operation import ServiceOperationQuery -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class WorkflowServicesManager(BaseEntity): +class WorkflowServicesManager(Entity): """Describes the workflow host configuration states and provides service objects that interact with the workflow.""" def get_workflow_instance_service(self): diff --git a/office365/sharepoint/yammer/wac_api.py b/office365/sharepoint/yammer/wac_api.py index 0cc318a60..78e05c223 100644 --- a/office365/sharepoint/yammer/wac_api.py +++ b/office365/sharepoint/yammer/wac_api.py @@ -1,5 +1,5 @@ -from office365.sharepoint.base_entity import BaseEntity +from office365.sharepoint.entity import Entity -class WacApi(BaseEntity): +class WacApi(Entity): pass