共用方式為


SignInManager<TUser>.SignInWithClaimsAsync 方法

定義

多載

SignInWithClaimsAsync(TUser, AuthenticationProperties, IEnumerable<Claim>)

登入指定的 user

SignInWithClaimsAsync(TUser, Boolean, IEnumerable<Claim>)

登入指定的 user

SignInWithClaimsAsync(TUser, AuthenticationProperties, IEnumerable<Claim>)

來源:
SignInManager.cs

登入指定的 user

public:
 virtual System::Threading::Tasks::Task ^ SignInWithClaimsAsync(TUser user, Microsoft::AspNetCore::Authentication::AuthenticationProperties ^ authenticationProperties, System::Collections::Generic::IEnumerable<System::Security::Claims::Claim ^> ^ additionalClaims);
public virtual System.Threading.Tasks.Task SignInWithClaimsAsync (TUser user, Microsoft.AspNetCore.Authentication.AuthenticationProperties authenticationProperties, System.Collections.Generic.IEnumerable<System.Security.Claims.Claim> additionalClaims);
public virtual System.Threading.Tasks.Task SignInWithClaimsAsync (TUser user, Microsoft.AspNetCore.Authentication.AuthenticationProperties? authenticationProperties, System.Collections.Generic.IEnumerable<System.Security.Claims.Claim> additionalClaims);
abstract member SignInWithClaimsAsync : 'User * Microsoft.AspNetCore.Authentication.AuthenticationProperties * seq<System.Security.Claims.Claim> -> System.Threading.Tasks.Task
override this.SignInWithClaimsAsync : 'User * Microsoft.AspNetCore.Authentication.AuthenticationProperties * seq<System.Security.Claims.Claim> -> System.Threading.Tasks.Task
Public Overridable Function SignInWithClaimsAsync (user As TUser, authenticationProperties As AuthenticationProperties, additionalClaims As IEnumerable(Of Claim)) As Task

參數

user
TUser

要登入的使用者。

authenticationProperties
AuthenticationProperties

套用至登入和驗證 Cookie 的屬性。

additionalClaims
IEnumerable<Claim>

將儲存在 Cookie 中的其他宣告。

傳回

工作物件,表示非同步作業。

適用於

SignInWithClaimsAsync(TUser, Boolean, IEnumerable<Claim>)

來源:
SignInManager.cs

登入指定的 user

public:
 virtual System::Threading::Tasks::Task ^ SignInWithClaimsAsync(TUser user, bool isPersistent, System::Collections::Generic::IEnumerable<System::Security::Claims::Claim ^> ^ additionalClaims);
public virtual System.Threading.Tasks.Task SignInWithClaimsAsync (TUser user, bool isPersistent, System.Collections.Generic.IEnumerable<System.Security.Claims.Claim> additionalClaims);
abstract member SignInWithClaimsAsync : 'User * bool * seq<System.Security.Claims.Claim> -> System.Threading.Tasks.Task
override this.SignInWithClaimsAsync : 'User * bool * seq<System.Security.Claims.Claim> -> System.Threading.Tasks.Task
Public Overridable Function SignInWithClaimsAsync (user As TUser, isPersistent As Boolean, additionalClaims As IEnumerable(Of Claim)) As Task

參數

user
TUser

要登入的使用者。

isPersistent
Boolean

旗標,指出登入 Cookie 是否應該在關閉瀏覽器之後保存。

additionalClaims
IEnumerable<Claim>

將儲存在 Cookie 中的其他宣告。

傳回

工作物件,表示非同步作業。

適用於