次の方法で共有


AuthenticationTokenExtensions.GetTokenAsync メソッド

定義

オーバーロード

GetTokenAsync(AuthenticationManager, String)
GetTokenAsync(IAuthenticationService, HttpContext, String)

指定した認証スキームを使用して要求を認証し、トークンの値を返します。

GetTokenAsync(AuthenticationManager, String, String)
GetTokenAsync(IAuthenticationService, HttpContext, String, String)

指定した認証スキームを使用して要求を認証し、トークンの値を返します。

GetTokenAsync(AuthenticationManager, String)

public:
[System::Runtime::CompilerServices::Extension]
 static System::Threading::Tasks::Task<System::String ^> ^ GetTokenAsync(Microsoft::AspNetCore::Http::Authentication::AuthenticationManager ^ manager, System::String ^ tokenName);
public static System.Threading.Tasks.Task<string> GetTokenAsync (this Microsoft.AspNetCore.Http.Authentication.AuthenticationManager manager, string tokenName);
static member GetTokenAsync : Microsoft.AspNetCore.Http.Authentication.AuthenticationManager * string -> System.Threading.Tasks.Task<string>
<Extension()>
Public Function GetTokenAsync (manager As AuthenticationManager, tokenName As String) As Task(Of String)

パラメーター

tokenName
String

戻り値

適用対象

GetTokenAsync(IAuthenticationService, HttpContext, String)

ソース:
TokenExtensions.cs
ソース:
TokenExtensions.cs
ソース:
TokenExtensions.cs

指定した認証スキームを使用して要求を認証し、トークンの値を返します。

public:
[System::Runtime::CompilerServices::Extension]
 static System::Threading::Tasks::Task<System::String ^> ^ GetTokenAsync(Microsoft::AspNetCore::Authentication::IAuthenticationService ^ auth, Microsoft::AspNetCore::Http::HttpContext ^ context, System::String ^ tokenName);
public static System.Threading.Tasks.Task<string> GetTokenAsync (this Microsoft.AspNetCore.Authentication.IAuthenticationService auth, Microsoft.AspNetCore.Http.HttpContext context, string tokenName);
public static System.Threading.Tasks.Task<string?> GetTokenAsync (this Microsoft.AspNetCore.Authentication.IAuthenticationService auth, Microsoft.AspNetCore.Http.HttpContext context, string tokenName);
static member GetTokenAsync : Microsoft.AspNetCore.Authentication.IAuthenticationService * Microsoft.AspNetCore.Http.HttpContext * string -> System.Threading.Tasks.Task<string>
<Extension()>
Public Function GetTokenAsync (auth As IAuthenticationService, context As HttpContext, tokenName As String) As Task(Of String)

パラメーター

context
HttpContext

HttpContextコンテキスト。

tokenName
String

トークンの名前。

戻り値

トークンの値 (存在する場合)。

適用対象

GetTokenAsync(AuthenticationManager, String, String)

public:
[System::Runtime::CompilerServices::Extension]
 static System::Threading::Tasks::Task<System::String ^> ^ GetTokenAsync(Microsoft::AspNetCore::Http::Authentication::AuthenticationManager ^ manager, System::String ^ signInScheme, System::String ^ tokenName);
public static System.Threading.Tasks.Task<string> GetTokenAsync (this Microsoft.AspNetCore.Http.Authentication.AuthenticationManager manager, string signInScheme, string tokenName);
static member GetTokenAsync : Microsoft.AspNetCore.Http.Authentication.AuthenticationManager * string * string -> System.Threading.Tasks.Task<string>
<Extension()>
Public Function GetTokenAsync (manager As AuthenticationManager, signInScheme As String, tokenName As String) As Task(Of String)

パラメーター

signInScheme
String
tokenName
String

戻り値

適用対象

GetTokenAsync(IAuthenticationService, HttpContext, String, String)

ソース:
TokenExtensions.cs
ソース:
TokenExtensions.cs
ソース:
TokenExtensions.cs

指定した認証スキームを使用して要求を認証し、トークンの値を返します。

public:
[System::Runtime::CompilerServices::Extension]
 static System::Threading::Tasks::Task<System::String ^> ^ GetTokenAsync(Microsoft::AspNetCore::Authentication::IAuthenticationService ^ auth, Microsoft::AspNetCore::Http::HttpContext ^ context, System::String ^ scheme, System::String ^ tokenName);
public static System.Threading.Tasks.Task<string> GetTokenAsync (this Microsoft.AspNetCore.Authentication.IAuthenticationService auth, Microsoft.AspNetCore.Http.HttpContext context, string scheme, string tokenName);
public static System.Threading.Tasks.Task<string?> GetTokenAsync (this Microsoft.AspNetCore.Authentication.IAuthenticationService auth, Microsoft.AspNetCore.Http.HttpContext context, string? scheme, string tokenName);
static member GetTokenAsync : Microsoft.AspNetCore.Authentication.IAuthenticationService * Microsoft.AspNetCore.Http.HttpContext * string * string -> System.Threading.Tasks.Task<string>
<Extension()>
Public Function GetTokenAsync (auth As IAuthenticationService, context As HttpContext, scheme As String, tokenName As String) As Task(Of String)

パラメーター

context
HttpContext

HttpContextコンテキスト。

scheme
String

認証スキームの名前。

tokenName
String

トークンの名前。

戻り値

トークンの値 (存在する場合)。

適用対象