Show / Hide Table of Contents

    Class IdentitySetExtensions

    Extentions for graph api contracts

    Inheritance
    Object
    IdentitySetExtensions
    Inherited Members
    Object.ToString()
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Namespace: Microsoft.Graph
    Assembly: Microsoft.Graph.Communications.Core.dll
    Syntax
    public static class IdentitySetExtensions

    Fields

    DodAppParticipantPrefix

    The application participant prefix for dod cloud

    Declaration
    public const string DodAppParticipantPrefix = "28:dod-global:"
    Field Value
    Type Description
    String

    DodDirectoryAppParticipantPrefix

    The directory application participant prefix for dod cloud

    Declaration
    public const string DodDirectoryAppParticipantPrefix = "28:dod:"
    Field Value
    Type Description
    String

    DodDirectoryParticipantPrefix

    The directory participant prefix for DoD cloud

    Declaration
    public const string DodDirectoryParticipantPrefix = "8:dod:"
    Field Value
    Type Description
    String

    DodOnPremisesParticipantPrefix

    The external prefix for DoD cloud

    Declaration
    public const string DodOnPremisesParticipantPrefix = "8:dod-sfb:"
    Field Value
    Type Description
    String

    EncryptedParticipantPrefix

    The encrypted participant prefix

    Declaration
    public const string EncryptedParticipantPrefix = "29:"
    Field Value
    Type Description
    String

    GcchAppParticipantPrefix

    The application participant prefix for gcch cloud

    Declaration
    public const string GcchAppParticipantPrefix = "28:gcch-global:"
    Field Value
    Type Description
    String

    GcchDirectoryAppParticipantPrefix

    The directory application participant prefix for gcch cloud

    Declaration
    public const string GcchDirectoryAppParticipantPrefix = "28:gcch:"
    Field Value
    Type Description
    String

    GcchDirectoryParticipantPrefix

    The directory participant prefix for GCCH cloud

    Declaration
    public const string GcchDirectoryParticipantPrefix = "8:gcch:"
    Field Value
    Type Description
    String

    GcchOnPremisesParticipantPrefix

    The external prefix for GCCH cloud

    Declaration
    public const string GcchOnPremisesParticipantPrefix = "8:gcch-sfb:"
    Field Value
    Type Description
    String

    PhoneParticipantPrefix

    The phone participant prefix

    Declaration
    public const string PhoneParticipantPrefix = "4:"
    Field Value
    Type Description
    String

    PublicAppParticipantPrefix

    The application participant prefix

    Declaration
    public const string PublicAppParticipantPrefix = "28:"
    Field Value
    Type Description
    String

    PublicDirectoryAppParticipantPrefix

    The directory application participant prefix for public cloud

    Declaration
    public const string PublicDirectoryAppParticipantPrefix = "28:orgid:"
    Field Value
    Type Description
    String

    PublicDirectoryParticipantPrefix

    The directory participant prefix for public cloud

    Declaration
    public const string PublicDirectoryParticipantPrefix = "8:orgid:"
    Field Value
    Type Description
    String

    PublicOnPremisesParticipantPrefix

    The external prefix for public cloud

    Declaration
    public const string PublicOnPremisesParticipantPrefix = "8:sfb:"
    Field Value
    Type Description
    String

    SkypeParticipantPrefix

    The skype participant prefix

    Declaration
    public const string SkypeParticipantPrefix = "8:"
    Field Value
    Type Description
    String

    TeamsVisitorParticipantPrefix

    The teams visitor participant prefix For anonymous users we need to support 8:teamsvisitor:objectId

    Declaration
    public const string TeamsVisitorParticipantPrefix = "8:teamsvisitor:"
    Field Value
    Type Description
    String

    Methods

    CreateIdentitySetByMri(String, String, String)

    Creates participant from MRI if possible. For chat service thread mris we return null

    Declaration
    public static IdentitySet CreateIdentitySetByMri(string mri, string tenantId, string displayName)
    Parameters
    Type Name Description
    String mri

    Participant MRI

    String tenantId

    The tenant identifier.

    String displayName

    The display name.

    Returns
    Type Description
    IdentitySet

    Created identity set

    Exceptions
    Type Condition
    ArgumentOutOfRangeException

    mri

    GetAppParticipantPrefix(CloudNamespace)

    Gets app participant prefix for the provided CloudNamespace.

    Declaration
    public static string GetAppParticipantPrefix(CloudNamespace cloudNamespace)
    Parameters
    Type Name Description
    CloudNamespace cloudNamespace

    The cloud where the app participant belongs

    Returns
    Type Description
    String

    Prefix to be used to construct the MRI

    GetDirectoryAppParticipantEnv(CloudNamespace)

    Returns the env differentiator part of the app participant prefix corresponding to cloudNamespace. This differentiator doesn't have participant prefix (8:, 4:, 28: or 29:) in it.

    Declaration
    public static string GetDirectoryAppParticipantEnv(CloudNamespace cloudNamespace)
    Parameters
    Type Name Description
    CloudNamespace cloudNamespace

    Cloud environment where the identity set belongs

    Returns
    Type Description
    String

    Env differentiator part of the app participant prefix corresponding to cloudNamespace

    GetDirectoryAppParticipantPrefix(CloudNamespace)

    Gets directory app participant prefix for the provided CloudNamespace.

    Declaration
    public static string GetDirectoryAppParticipantPrefix(CloudNamespace cloudNamespace)
    Parameters
    Type Name Description
    CloudNamespace cloudNamespace

    The cloud where the directory app participant belongs

    Returns
    Type Description
    String

    Prefix to be used to construct the MRI

    GetDirectoryParticipantPrefix(CloudNamespace)

    Gets a user prefix for the provided CloudNamespace.

    Declaration
    public static string GetDirectoryParticipantPrefix(CloudNamespace cloudNamespace)
    Parameters
    Type Name Description
    CloudNamespace cloudNamespace

    The cloud where the user belongs

    Returns
    Type Description
    String

    Prefix to be used to construct the MRI

    GetEnumerator(IdentitySet)

    Enumerates through all the Identity objects found in this IdentitySet

    Declaration
    public static IEnumerable<KeyValuePair<string, Identity>> GetEnumerator(this IdentitySet identitySet)
    Parameters
    Type Name Description
    IdentitySet identitySet

    The identity set.

    Returns
    Type Description
    IEnumerable<KeyValuePair<String, Identity>>

    The IEnumerable{KeyValuePair{string, Identity}} for the specified IdentitySet.

    GetMri(IdentitySet, CloudNamespace)

    Gets participant MRI The priority order is: User, Guest, Encrypted, Application Instance, Application, Phone

    Declaration
    public static string GetMri(this IdentitySet identitySet, CloudNamespace cloudNamespace)
    Parameters
    Type Name Description
    IdentitySet identitySet

    Participant identity set

    CloudNamespace cloudNamespace

    Cloud environment where the identity set belongs

    Returns
    Type Description
    String

    Participant MRI

    GetObjectIdForAppParticipant(String)

    Get the object id for an app

    Declaration
    public static string GetObjectIdForAppParticipant(string mri)
    Parameters
    Type Name Description
    String mri

    participant mri

    Returns
    Type Description
    String

    The object id of the participant>

    GetObjectIdForDirectoryAppParticipant(String)

    Get the object id for a directory app participant

    Declaration
    public static string GetObjectIdForDirectoryAppParticipant(string mri)
    Parameters
    Type Name Description
    String mri

    participant mri

    Returns
    Type Description
    String

    The object id of the participant>

    GetObjectIdForDirectoryParticipant(String)

    /Get the object id for a directory participant

    Declaration
    public static string GetObjectIdForDirectoryParticipant(string mri)
    Parameters
    Type Name Description
    String mri

    participant mri

    Returns
    Type Description
    String

    The object id of the participant>

    GetObjectIdForOnPremisesParticipant(String)

    /Get the object id for an external participant

    Declaration
    public static string GetObjectIdForOnPremisesParticipant(string mri)
    Parameters
    Type Name Description
    String mri

    participant mri

    Returns
    Type Description
    String

    The object id of the participant>

    GetOnPremisesParticipantPrefix(CloudNamespace)

    Gets an external prefix for the provided CloudNamespace.

    Declaration
    public static string GetOnPremisesParticipantPrefix(CloudNamespace cloudNamespace)
    Parameters
    Type Name Description
    CloudNamespace cloudNamespace

    The cloud where the user belongs

    Returns
    Type Description
    String

    Prefix to be used to construct the MRI

    GetPrimaryIdentity(IdentitySet)

    Gets the primary identity from the specified IdentitySet. The priority order is: User, Guest, Phone, Encrypted, OnPremises, Application Instance, Application

    Declaration
    public static Identity GetPrimaryIdentity(this IdentitySet identitySet)
    Parameters
    Type Name Description
    IdentitySet identitySet

    The identity set.

    Returns
    Type Description
    Identity

    Primary Identity

    IsConsumer(IdentitySet)

    Indicates whether this identity set is a consumer identity.

    Declaration
    public static bool IsConsumer(this IdentitySet identitySet)
    Parameters
    Type Name Description
    IdentitySet identitySet

    The identity set.

    Returns
    Type Description
    Boolean

    true if the identity is a consumer identity, false otherwise.

    MriHasAppParticipantPrefix(String)

    Returns whether a MRI is a directory participant prefix or not.

    Declaration
    public static bool MriHasAppParticipantPrefix(string mri)
    Parameters
    Type Name Description
    String mri

    Participant MRI

    Returns
    Type Description
    Boolean
    true
    if mri is a valid directory participant prefix

    MriHasDirectoryAppParticipantPrefix(String)

    Returns whether a MRI is a directory participant prefix or not.

    Declaration
    public static bool MriHasDirectoryAppParticipantPrefix(string mri)
    Parameters
    Type Name Description
    String mri

    Participant MRI

    Returns
    Type Description
    Boolean
    true
    if mri is a valid directory participant prefix

    MriHasDirectoryParticipantPrefix(String)

    Returns whether a MRI is a directory participant prefix or not.

    Declaration
    public static bool MriHasDirectoryParticipantPrefix(string mri)
    Parameters
    Type Name Description
    String mri

    Participant MRI

    Returns
    Type Description
    Boolean
    true
    if mri is a valid directory participant prefix

    MriHasOnPremisesParticipantPrefix(String)

    Returns whether a MRI is an external participant prefix or not.

    Declaration
    public static bool MriHasOnPremisesParticipantPrefix(string mri)
    Parameters
    Type Name Description
    String mri

    Participant MRI

    Returns
    Type Description
    Boolean
    true
    if mri is a valid external participant prefix
    Back to top Copyright (c) Microsoft Corporation. All rights reserved.