InternalFindFolders method

Future<ServiceResponseCollection<FindFolderResponse>> InternalFindFolders(
  1. Iterable<FolderId> parentFolderIds,
  2. SearchFilter? searchFilter,
  3. FolderView view,
  4. ServiceErrorHandling errorHandlingMode,
)
Copies a folder. Calling this method results in a call to EWS. The folder id. The destination folder id. Move a folder. The folder id. The destination folder id. Finds folders. The parent folder ids. The search filter. Available search filter classes include SearchFilter.IsEqualTo, SearchFilter.ContainsSubstring and SearchFilter.SearchFilterCollection The view controlling the number of folders returned. Indicates the type of error handling should be done.

Implementation

//        Folder CopyFolder(
//            FolderId folderId,
//            FolderId destinationFolderId)
//        {
//            CopyFolderRequest request = new CopyFolderRequest(this, ServiceErrorHandling.ThrowOnError);
//
//            request.DestinationFolderId = destinationFolderId;
//            request.FolderIds.Add(folderId);
//
//            ServiceResponseCollection<MoveCopyFolderResponse> responses = request.Execute();
//
//            return responses[0].Folder;
//        }

/// <summary>
/// Move a folder.
/// </summary>
/// <param name="folderId">The folder id.</param>
/// <param name="destinationFolderId">The destination folder id.</param>
/// <returns>Moved folder.</returns>
//        Folder MoveFolder(
//            FolderId folderId,
//            FolderId destinationFolderId)
//        {
//            MoveFolderRequest request = new MoveFolderRequest(this, ServiceErrorHandling.ThrowOnError);
//
//            request.DestinationFolderId = destinationFolderId;
//            request.FolderIds.Add(folderId);
//
//            ServiceResponseCollection<MoveCopyFolderResponse> responses = request.Execute();
//
//            return responses[0].Folder;
//        }

/// <summary>
/// Finds folders.
/// </summary>
/// <param name="parentFolderIds">The parent folder ids.</param>
/// <param name="searchFilter">The search filter. Available search filter classes
/// include SearchFilter.IsEqualTo, SearchFilter.ContainsSubstring and
/// SearchFilter.SearchFilterCollection</param>
/// <param name="view">The view controlling the number of folders returned.</param>
/// <param name="errorHandlingMode">Indicates the type of error handling should be done.</param>
/// <returns>Collection of service responses.</returns>
Future<ServiceResponseCollection<FindFolderResponse>> InternalFindFolders(
    Iterable<FolderId> parentFolderIds,
    SearchFilter? searchFilter,
    FolderView view,
    ServiceErrorHandling errorHandlingMode) {
  FindFolderRequest request = new FindFolderRequest(this, errorHandlingMode);

  request.ParentFolderIds.AddRangeFolderIds(parentFolderIds);
  request.SearchFilter = searchFilter;
  request.View = view;

  return request.Execute();
}