Share via


IRoleStore<TRole>.FindByIdAsync(String, CancellationToken) Methode

Definition

Sucht die Rolle, die über die angegebene ID als asynchronen Vorgang verfügt.

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

Parameter

roleId
String

Die zu suchende Rollen-ID.

cancellationToken
CancellationToken

Die CancellationToken-Struktur, mit der Benachrichtigungen verteilt werden, dass der Vorgang abgebrochen werden muss.

Gibt zurück

Task<TRole>

Ein Task<TResult> Ergebnis der Suche.

Gilt für: