Share via


UserStore<TUser, TRole, TKey, TUserLogin, TUserRole, TUserClaim>.GetRolesAsync Method (TUser)

 

Asynchronously gets the names of the roles a user is a member of.

Namespace:   Microsoft.AspNet.Identity.EntityFramework
Assembly:  Microsoft.AspNet.Identity.EntityFramework (in Microsoft.AspNet.Identity.EntityFramework.dll)

Syntax

public virtual Task<IList<string>> GetRolesAsync(
    TUser user
)
public:
virtual Task<IList<String^>^>^ GetRolesAsync(
    TUser user
)
abstract GetRolesAsync : 
        user:'TUser -> Task<IList<string>>
override GetRolesAsync : 
        user:'TUser -> Task<IList<string>>
Public Overridable Function GetRolesAsync (
    user As TUser
) As Task(Of IList(Of String))

Parameters

  • user
    Type: TUser

    The user.

Return Value

Type: System.Threading.Tasks.Task<IList<String>>

The task representing the asynchronous operation.

Implements

IUserRoleStore<TUser, TKey>.GetRolesAsync(TUser)

See Also

UserStore<TUser, TRole, TKey, TUserLogin, TUserRole, TUserClaim> Class
Microsoft.AspNet.Identity.EntityFramework Namespace
ASP.NET Identity

Return to top