IIdentityManagementService.ReadIdentity Method (IdentitySearchFactor, String, MembershipQuery, ReadIdentityOptions)
Overload that takes a single search factor and returns match following this order.
1. With multiple matches, active identity if exists, else first match.
2. When there is a single match, the match.
3. When there is no match, null.
Read identity based on search factor. First read from IMS store, and then (optionally) read from source like AD.
Assembly: Microsoft.TeamFoundation.Client (in Microsoft.TeamFoundation.Client.dll)
TeamFoundationIdentity ReadIdentity( IdentitySearchFactor searchFactor, string searchFactorValue, MembershipQuery queryMembership, ReadIdentityOptions readOptions )
- Type: Microsoft.TeamFoundation.Framework.Common.IdentitySearchFactor
how search is specified (by account name, etc.)
- Type: System.String
actual search string (account name, etc.)
- Type: Microsoft.TeamFoundation.Framework.Common.MembershipQuery
none, direct or expanded membership information
- Type: Microsoft.TeamFoundation.Framework.Common.ReadIdentityOptions
readOptions, such as reading from source
Return ValueType: Microsoft.TeamFoundation.Framework.Client.TeamFoundationIdentity
Array of matching identities
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.