SPClaimProviderOperations.GetHierarchy method (Uri, SPClaimProviderOperationOptions, String, String[], String, Int32)
Gets the hierarchy tree starting at the specified node for the specified claims providers in the context with an operation option.
Namespace: Microsoft.SharePoint.Administration.Claims
Assembly: Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Syntax
'Declaration
Public Shared Function GetHierarchy ( _
context As Uri, _
mode As SPClaimProviderOperationOptions, _
providerName As String, _
entityTypes As String(), _
hierarchyNodeID As String, _
numberOfLevels As Integer _
) As SPProviderHierarchyTree
'Usage
Dim context As Uri
Dim mode As SPClaimProviderOperationOptions
Dim providerName As String
Dim entityTypes As String()
Dim hierarchyNodeID As String
Dim numberOfLevels As Integer
Dim returnValue As SPProviderHierarchyTree
returnValue = SPClaimProviderOperations.GetHierarchy(context, _
mode, providerName, entityTypes, _
hierarchyNodeID, numberOfLevels)
public static SPProviderHierarchyTree GetHierarchy(
Uri context,
SPClaimProviderOperationOptions mode,
string providerName,
string[] entityTypes,
string hierarchyNodeID,
int numberOfLevels
)
Parameters
context
Type: System.UriThe context within which the claims providers can be found.
mode
Type: Microsoft.SharePoint.Administration.Claims.SPClaimProviderOperationOptionsThe operation option to get the claims providers.
providerName
Type: System.StringThe names of the claims providers from which the hierarchy tree is retrieved.
entityTypes
Type: []The entity types that are returned on the hierarchy tree.
hierarchyNodeID
Type: System.StringThe ID of the node from which the hierarchy is determined.
numberOfLevels
Type: System.Int32The number of hierarchy levels to return.
Return value
Type: Microsoft.SharePoint.WebControls.SPProviderHierarchyTree
The hierarchy tree returned by the specified claims provider.
Exceptions
Exception | Condition |
---|---|
ArgumentNullException | context or providerName is null . |
ArgumentOutOfRangeException | numberOfLevels is less than 1. |
Remarks
For more information about claims picking and resolution, see How to: Create a Claims Provider and Claims Provider.
See also
Reference
SPClaimProviderOperations class