SyncFolderHierarchy method

Future<ChangeCollection<FolderChange>> SyncFolderHierarchy(
  1. FolderId syncFolderId,
  2. PropertySet propertySet,
  3. String? syncState
)
Synchronizes the sub-folders of a specific folder. Calling this method results in a call to EWS. The Id of the folder containing the items to synchronize with. A null value indicates the root folder of the mailbox. The set of properties to retrieve for synchronized items. The optional sync state representing the point in time when to start the synchronization.

Implementation

Future<ChangeCollection<FolderChange>> SyncFolderHierarchy(
    FolderId syncFolderId, PropertySet propertySet, String? syncState) async {
  final request = await this
      .BuildSyncFolderHierarchyRequest(syncFolderId, propertySet, syncState);
  final ServiceResponseCollection<SyncFolderHierarchyResponse> response =
      await request.Execute();
  return response[0].Changes;
}