共用方式為


IRoleStore<TRole>.GetNormalizedRoleNameAsync 方法

定義

取得角色的標準化名稱作為非同步作業。

public:
 System::Threading::Tasks::Task<System::String ^> ^ GetNormalizedRoleNameAsync(TRole role, System::Threading::CancellationToken cancellationToken);
public System.Threading.Tasks.Task<string> GetNormalizedRoleNameAsync (TRole role, System.Threading.CancellationToken cancellationToken);
public System.Threading.Tasks.Task<string?> GetNormalizedRoleNameAsync (TRole role, System.Threading.CancellationToken cancellationToken);
abstract member GetNormalizedRoleNameAsync : 'Role * System.Threading.CancellationToken -> System.Threading.Tasks.Task<string>
Public Function GetNormalizedRoleNameAsync (role As TRole, cancellationToken As CancellationToken) As Task(Of String)

參數

role
TRole

應該擷取正規化名稱的角色。

cancellationToken
CancellationToken

用於散佈應取消作業通知的 CancellationToken

傳回

包含角色名稱的 Task<TResult>

適用於