com.microsoft.tfs.core.clients.webservices
Interface IIdentityManagementService

All Known Subinterfaces:
IIdentityManagementService2
All Known Implementing Classes:
IdentityManagementService, IdentityManagementService2

public interface IIdentityManagementService

Since:
TEE-SDK-11.0

Method Summary
 void addMemberToApplicationGroup(IdentityDescriptor groupDescriptor, IdentityDescriptor descriptor)
          Add member to TFS Group.
 IdentityDescriptor createApplicationGroup(java.lang.String projectUri, java.lang.String groupName, java.lang.String groupDescription)
          Creates a TFS application group
 void deleteApplicationGroup(IdentityDescriptor groupDescriptor)
          Deletes a TFS application group
 java.lang.String getIdentityDomainScope()
           
 java.lang.String getScopeName(java.lang.String scopeId)
          Gets the scope name for the provided scope id.
 boolean isMember(IdentityDescriptor groupDescriptor, IdentityDescriptor descriptor)
          Expanded membership query for direct or nested member.
 boolean isOwnedWellKnownGroup(IdentityDescriptor descriptor)
          Check if the given descriptor is of TeamFoundation type, belongs to this IMS host and is a well-known group.
 boolean isOwner(IdentityDescriptor descriptor)
          Check if the given descriptor is of TeamFoundation type, and belongs to this IMS host.
 TeamFoundationIdentity[] listApplicationGroups(java.lang.String projectUri, ReadIdentityOptions readOptions)
          Lists all TFS application groups within the specified scope
 TeamFoundationIdentity[] readIdentities(com.microsoft.tfs.util.GUID[] teamFoundationIds, MembershipQuery queryMembership)
          Read identities by Team Foundation Id.
 TeamFoundationIdentity[] readIdentities(IdentityDescriptor[] descriptors, MembershipQuery queryMembership, ReadIdentityOptions readOptions)
          Read identities for given descriptors.
 TeamFoundationIdentity[][] readIdentities(IdentitySearchFactor searchFactor, java.lang.String[] searchFactorValues, MembershipQuery queryMembership, ReadIdentityOptions readOptions)
          Read identities based on search factor.
 TeamFoundationIdentity readIdentity(IdentityDescriptor descriptor, MembershipQuery queryMembership, ReadIdentityOptions readOptions)
          Overload that takes a single descriptor.
 TeamFoundationIdentity readIdentity(IdentitySearchFactor searchFactor, java.lang.String searchFactorValue, MembershipQuery queryMembership, ReadIdentityOptions readOptions)
          Overload that takes a single search factor and returns match following this order.
 boolean refreshIdentity(IdentityDescriptor descriptor)
          Refresh identity properties from provider now.
 void removeMemberFromApplicationGroup(IdentityDescriptor groupDescriptor, IdentityDescriptor descriptor)
          Remove member from TFS Group.
 void updateApplicationGroup(IdentityDescriptor groupDescriptor, GroupProperty groupProperty, java.lang.String newValue)
          Updates a property of a TFS application group
 

Method Detail

readIdentities

TeamFoundationIdentity[] readIdentities(IdentityDescriptor[] descriptors,
                                        MembershipQuery queryMembership,
                                        ReadIdentityOptions readOptions)
Read identities for given descriptors. First try IMS store. If not found, optionally try source like AD. Note - performance will be fastest when no membership information is requested.

Parameters:
descriptors - descriptors (descriptor is identity type + identifier)
queryMembership - none, direct or expanded membership information
readOptions - read options, such as reading from source
Returns:
Array of identities, corresponding 1 to 1 with input descriptor array.

readIdentity

TeamFoundationIdentity readIdentity(IdentityDescriptor descriptor,
                                    MembershipQuery queryMembership,
                                    ReadIdentityOptions readOptions)
Overload that takes a single descriptor. Read identity for given descriptor. First try IMS store. If not found, optionally try source like AD. Note - performance will be fastest when no membership information is requested.

Parameters:
descriptor - identity type + identifier
queryMembership - none, direct or expanded membership information
readOptions - read options, such as reading from source
Returns:
identity if found, else null

readIdentities

TeamFoundationIdentity[] readIdentities(com.microsoft.tfs.util.GUID[] teamFoundationIds,
                                        MembershipQuery queryMembership)
Read identities by Team Foundation Id. Note - performance will be fastest when no membership information is requested.

Parameters:
teamFoundationIds - identity ids
queryMembership - none, direct or expanded membership information
Returns:
Array of identities, corresponding 1 to 1 with input array

readIdentities

TeamFoundationIdentity[][] readIdentities(IdentitySearchFactor searchFactor,
                                          java.lang.String[] searchFactorValues,
                                          MembershipQuery queryMembership,
                                          ReadIdentityOptions readOptions)
Read identities based on search factor. First read from IMS store, then (optionally) read from source like AD.

Parameters:
searchFactor - how search is specified (by account name, etc.)
searchFactorValues - actual search strings (account names, etc.)
queryMembership - none, direct or expanded membership information
readOptions - readOptions, such as reading from source
Returns:
Arrays of identities. Inner array corresponds 1 to 1 with search factor values

readIdentity

TeamFoundationIdentity readIdentity(IdentitySearchFactor searchFactor,
                                    java.lang.String searchFactorValue,
                                    MembershipQuery queryMembership,
                                    ReadIdentityOptions readOptions)
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, then (optionally) read from source like AD.

Parameters:
searchFactor - how search is specified (by account name, etc.)
searchFactorValue - actual search string (account name, etc.)
queryMembership - none, direct or expanded membership information
readOptions - readOptions, such as reading from source
Returns:
Array of matching identities

createApplicationGroup

IdentityDescriptor createApplicationGroup(java.lang.String projectUri,
                                          java.lang.String groupName,
                                          java.lang.String groupDescription)
Creates a TFS application group

Parameters:
projectUri - Scope Uri, specifying whether group scope is project level or global to this host. Null or empty value signifies global scope
groupName - name
groupDescription - description. can be null
Returns:
IdentityDescriptor of the created group

listApplicationGroups

TeamFoundationIdentity[] listApplicationGroups(java.lang.String projectUri,
                                               ReadIdentityOptions readOptions)
Lists all TFS application groups within the specified scope

Parameters:
projectUri - Scope Uri, specifying whether group scope is project level or global to this host. Null or empty value signifies global scope
readOptions - read options
Returns:
Application groups as an array of identities

updateApplicationGroup

void updateApplicationGroup(IdentityDescriptor groupDescriptor,
                            GroupProperty groupProperty,
                            java.lang.String newValue)
Updates a property of a TFS application group

Parameters:
groupDescriptor -
groupProperty - which property to update
newValue - the new value for the property

deleteApplicationGroup

void deleteApplicationGroup(IdentityDescriptor groupDescriptor)
Deletes a TFS application group

Parameters:
groupDescriptor - groupDescriptor

addMemberToApplicationGroup

void addMemberToApplicationGroup(IdentityDescriptor groupDescriptor,
                                 IdentityDescriptor descriptor)
Add member to TFS Group.

Parameters:
groupDescriptor - groupDescriptor
descriptor - member

removeMemberFromApplicationGroup

void removeMemberFromApplicationGroup(IdentityDescriptor groupDescriptor,
                                      IdentityDescriptor descriptor)
Remove member from TFS Group.

Parameters:
groupDescriptor - groupDescriptor
descriptor - member

isMember

boolean isMember(IdentityDescriptor groupDescriptor,
                 IdentityDescriptor descriptor)
Expanded membership query for direct or nested member.

Parameters:
groupDescriptor - group
descriptor - member

refreshIdentity

boolean refreshIdentity(IdentityDescriptor descriptor)
Refresh identity properties from provider now. This identity must already be in the IMS store. If identity is a group, its DIRECT members and their properties will also be refreshed (asynchronously).

Identity properties, such as display name, are synced from the provider over a 24h cylce, by default. Use this API to sync now.

Parameters:
descriptor - identity specification. Null implies caller
Returns:
True if identity is in IMS (in which case will be refreshed now), else false.

getScopeName

java.lang.String getScopeName(java.lang.String scopeId)
Gets the scope name for the provided scope id.

Parameters:
scopeId - scope id, which is the project or domain Uri
Returns:
The scope name.

isOwner

boolean isOwner(IdentityDescriptor descriptor)
Check if the given descriptor is of TeamFoundation type, and belongs to this IMS host. This does not confirm that such a group actually exists, just that the Sid pattern belongs to this host.

Parameters:
descriptor -
Returns:
True if owner, else false.

isOwnedWellKnownGroup

boolean isOwnedWellKnownGroup(IdentityDescriptor descriptor)
Check if the given descriptor is of TeamFoundation type, belongs to this IMS host and is a well-known group. This does not confirm that such a group actually exists, just that the Sid pattern meets these requirements.

Parameters:
descriptor -
Returns:
True if owned and is well-known group.

getIdentityDomainScope

java.lang.String getIdentityDomainScope()
Returns:
Return the Scope Uri for global Groups in the domain


© 2015 Microsoft. All rights reserved.