Hi Chris,
We plan to update the FileExplorer online documentation next week as part of our RadControls service pack release and offer much more detailed information about the file browser content provider model.
The
ResolveRootDirectoryAsTree method is called when the FileExplorer control wants to get the subfolders of a particular folder. Since the folders in the explorer tree are expanded using ajax requests, the function is called for each expanded folders. If you are concerned about the performance of your provider, you should make the function return only one level of child folders. For example if you have the following folder structure:
root_folder
- sub_folder1
- sub_folder2
-sub_sub_folder1
-sub_sub_folder2
- sub_folder3
If you call the ResolveRootDirectoryAsTree method for the "root_folder" above, you should only return "sub_folder1","sub_folder2", and "sub_folder3" in the list of sub-folders. There is no need to go further down in the folder structure and return the subfolders of "sub_folder2". Note that you can also skip the files. Only the folders are important in the return value of this method.
The ResolveDirectory method is called for two reasons - to get the files in a particular folder and to check a folder's permissions.
To populate the file explorer's grid control, we first call ResolveRootDirectoryAsTree to get the sub-folders of the current folder and then ResolveDirectory to get the files.
Best wishes,
Lini
the Telerik team