ClaimsPrincipal.PrimaryIdentitySelector 属性

定义

获取或设置用于选择 Identity 属性返回的声明标识的委托。Gets or sets the delegate used to select the claims identity returned by the Identity property.

public:
 static property Func<System::Collections::Generic::IEnumerable<System::Security::Claims::ClaimsIdentity ^> ^, System::Security::Claims::ClaimsIdentity ^> ^ PrimaryIdentitySelector { Func<System::Collections::Generic::IEnumerable<System::Security::Claims::ClaimsIdentity ^> ^, System::Security::Claims::ClaimsIdentity ^> ^ get(); void set(Func<System::Collections::Generic::IEnumerable<System::Security::Claims::ClaimsIdentity ^> ^, System::Security::Claims::ClaimsIdentity ^> ^ value); };
[set: System.Security.SecurityCritical]
public static Func<System.Collections.Generic.IEnumerable<System.Security.Claims.ClaimsIdentity>,System.Security.Claims.ClaimsIdentity> PrimaryIdentitySelector { get; set; }
public static Func<System.Collections.Generic.IEnumerable<System.Security.Claims.ClaimsIdentity>,System.Security.Claims.ClaimsIdentity?> PrimaryIdentitySelector { get; set; }
public static Func<System.Collections.Generic.IEnumerable<System.Security.Claims.ClaimsIdentity>,System.Security.Claims.ClaimsIdentity> PrimaryIdentitySelector { get; set; }
[<set: System.Security.SecurityCritical>]
member this.PrimaryIdentitySelector : Func<seq<System.Security.Claims.ClaimsIdentity>, System.Security.Claims.ClaimsIdentity> with get, set
member this.PrimaryIdentitySelector : Func<seq<System.Security.Claims.ClaimsIdentity>, System.Security.Claims.ClaimsIdentity> with get, set
Public Shared Property PrimaryIdentitySelector As Func(Of IEnumerable(Of ClaimsIdentity), ClaimsIdentity)

属性值

Func<IEnumerable<ClaimsIdentity>,ClaimsIdentity>

委托。The delegate. 默认值为 nullThe default is null.

属性

注解

可以设置此属性来重写属性的默认行为 IdentityYou can set this property to override the default behavior of the Identity property.

适用于

另请参阅