Share via


SPFolderHierarchy members

This class is an abstraction over the folders in a SharePoint Server list designed to work around limitations in the SharePoint Server object model around iterating the folders in a large list.

The SPFolderHierarchy type exposes the following members.

Constructors

  Name Description
Public method SPFolderHierarchy(SPList) Initializes a new instance of a SPFolderHierarchy object
Public method SPFolderHierarchy(SPList, Boolean) Initializes a new instance of a collection of all folders in the list.
Public method SPFolderHierarchy(SPList, String, Boolean) Initializes a new instance of a SPFolderHierarchy object.
Public method SPFolderHierarchy(SPList, Boolean, String, Boolean) Initializes a new instance of a collection of all folders in the list.

Top

Properties

  Name Description
Public property Count Count Gets the number of folders in this hierarchy.
Public property FolderUrl FolderUrl The url of the folder corresponding to this hierarchy of folders.
Public property IncludeDocsets Gets whether the hierarchy of folders includes document sets.
Public property Item Gets a folder by server-relative url.
Public property List List Gets the list corresponding to this hierarchy of folders.
Public property ParentHierarchy ParentHierarchy Gets the hierarchy of folders for the parent of this hierarchy.
Public property RootHierarchy RootHierarchy Gets the hierarchy of folders for the root of this hierarchy.
Public property ThrottledMode Gets whether the folder hierarchy is in throttled mode.

Top

Methods

  Name Description
Public method GetEnumerator Get enumerator.
Public methodStatic member GetFolderSubFolderCount Gets the count of subfolders for the specified SPFolder object.
Public methodStatic member GetSiteCollectionResourceFolder Gets a folder for storing resources for a site collection.
Public methodStatic member GetSubFolder Gets the direct subfolder by name.
Public method GetSubFolders(String) Gets the subfolder of the folder indicated by the URL.
Public method GetSubFolders(String, Boolean) Gets the subfolders of a folder indicated by the URL.
Public methodStatic member ListHasFolders Checks whether the list has folders.
Public method TryGetFolder TryGetFolder Gets a folder by url, or null if the folder doesn't exist.
Public methodStatic member TryGetFolderByUrl(SPWeb, String, SPFolder) TryGetFolderByUrl Gets a folder by the server-relative url.
Public methodStatic member TryGetFolderByUrl(SPWeb, String, Boolean, SPFolder) TryGetFolderByUrl Gets a folder by the server-relative url.
Public method TryGetFolderItem TryGetFolderItem Gets a folder by url, or null if the folder doesn't exist.

Top

See also

Reference

SPFolderHierarchy class

Microsoft.Office.Server.Utilities namespace