TeamFoundationIdentityService.ReadIdentity Method (TeamFoundationRequestContext, IdentitySearchFactor, String, MembershipQuery, ReadIdentityOptions, IEnumerable<String>)

Overload that takes a single search factor and returns match following this order.

1. When there is no match, null.

2. When there is a single match, that identity regardless of whether the identity is active.

3. When there is a single active identity match, that identity.

Namespace: Microsoft.TeamFoundation.Framework.Server
Assembly: Microsoft.TeamFoundation.Framework.Server (in Microsoft.TeamFoundation.Framework.Server.dll)

Syntax

'Declaration
Public Function ReadIdentity ( _
    requestContext As TeamFoundationRequestContext, _
    searchFactor As IdentitySearchFactor, _
    factorValue As String, _
    queryMembership As MembershipQuery, _
    readOptions As ReadIdentityOptions, _
    propertyNameFilters As IEnumerable(Of String) _
) As TeamFoundationIdentity
public TeamFoundationIdentity ReadIdentity(
    TeamFoundationRequestContext requestContext,
    IdentitySearchFactor searchFactor,
    string factorValue,
    MembershipQuery queryMembership,
    ReadIdentityOptions readOptions,
    IEnumerable<string> propertyNameFilters
)
public:
virtual TeamFoundationIdentity^ ReadIdentity(
    TeamFoundationRequestContext^ requestContext, 
    IdentitySearchFactor searchFactor, 
    String^ factorValue, 
    MembershipQuery queryMembership, 
    ReadIdentityOptions readOptions, 
    IEnumerable<String^>^ propertyNameFilters
) sealed
abstract ReadIdentity : 
        requestContext:TeamFoundationRequestContext * 
        searchFactor:IdentitySearchFactor * 
        factorValue:string * 
        queryMembership:MembershipQuery * 
        readOptions:ReadIdentityOptions * 
        propertyNameFilters:IEnumerable<string> -> TeamFoundationIdentity  
override ReadIdentity : 
        requestContext:TeamFoundationRequestContext * 
        searchFactor:IdentitySearchFactor * 
        factorValue:string * 
        queryMembership:MembershipQuery * 
        readOptions:ReadIdentityOptions * 
        propertyNameFilters:IEnumerable<string> -> TeamFoundationIdentity
public final function ReadIdentity(
    requestContext : TeamFoundationRequestContext, 
    searchFactor : IdentitySearchFactor, 
    factorValue : String, 
    queryMembership : MembershipQuery, 
    readOptions : ReadIdentityOptions, 
    propertyNameFilters : IEnumerable<String>
) : TeamFoundationIdentity

Parameters

Return Value

Type: Microsoft.TeamFoundation.Framework.Server.TeamFoundationIdentity
Returns TeamFoundationIdentity.

Implements

ITeamFoundationIdentityService.ReadIdentity(TeamFoundationRequestContext, IdentitySearchFactor, String, MembershipQuery, ReadIdentityOptions, IEnumerable<String>)

Exceptions

Exception Condition
MultipleIdentitiesFoundException

Thrown when there are multiple matches, unless exactly one identity is active.

.NET Framework Security

See Also

Reference

TeamFoundationIdentityService Class

ReadIdentity Overload

Microsoft.TeamFoundation.Framework.Server Namespace