共用方式為


SPClaimProvider.Search Method

Performs a search of the SPProviderHierarchyTree hierarchy.

Namespace:  Microsoft.SharePoint.Administration.Claims
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)

Syntax

'Declaration
Public Function Search ( _
    context As Uri, _
    entityTypes As String(), _
    searchPattern As String, _
    hierarchyNodeID As String, _
    maxCount As Integer _
) As SPProviderHierarchyTree
'Usage
Dim instance As SPClaimProvider
Dim context As Uri
Dim entityTypes As String()
Dim searchPattern As String
Dim hierarchyNodeID As String
Dim maxCount As Integer
Dim returnValue As SPProviderHierarchyTree

returnValue = instance.Search(context, _
    entityTypes, searchPattern, hierarchyNodeID, _
    maxCount)
public SPProviderHierarchyTree Search(
    Uri context,
    string[] entityTypes,
    string searchPattern,
    string hierarchyNodeID,
    int maxCount
)

Parameters

  • context
    Type: System.Uri

    The context, as a URI. This must be a properly formatted URI.

  • hierarchyNodeID
    Type: System.String

    The node to search from. The HierarchyNodeID() identifies the node to search from. If a null reference (Nothing in Visual Basic) then the search begins at the root.

Return Value

Type: Microsoft.SharePoint.WebControls.SPProviderHierarchyTree
A SPProviderHierarchyTree tree from the root node or from hierarchyNodeID to all tree nodes and nodes containing the matching PickerEntity objects.

Exceptions

Exception Condition
ArgumentNullException

Thrown when context is a null reference (Nothing in Visual Basic).

ArgumentOutOfRangeException

Thrown when maxCount is less than 0.

NotImplementedException

Thrown when SupportsSearch is false.

See Also

Reference

SPClaimProvider Class

SPClaimProvider Members

Microsoft.SharePoint.Administration.Claims Namespace