RoleManager<TRole>.FindByNameAsync(String) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Finds the role associated with the specified roleName
if any.
public:
virtual System::Threading::Tasks::Task<TRole> ^ FindByNameAsync(System::String ^ roleName);
public virtual System.Threading.Tasks.Task<TRole> FindByNameAsync (string roleName);
public virtual System.Threading.Tasks.Task<TRole?> FindByNameAsync (string roleName);
abstract member FindByNameAsync : string -> System.Threading.Tasks.Task<'Role (requires 'Role : null)>
override this.FindByNameAsync : string -> System.Threading.Tasks.Task<'Role (requires 'Role : null)>
Public Overridable Function FindByNameAsync (roleName As String) As Task(Of TRole)
Parameters
- roleName
- String
The name of the role to be returned.
Returns
Task<TRole>
The Task that represents the asynchronous operation, containing the role
associated with the specified roleName