UserManager<TUser>.RemoveFromRoleAsync(TUser, String) 方法

定义

从命名角色中删除指定的 user

public:
 virtual System::Threading::Tasks::Task<Microsoft::AspNetCore::Identity::IdentityResult ^> ^ RemoveFromRoleAsync(TUser user, System::String ^ role);
public virtual System.Threading.Tasks.Task<Microsoft.AspNetCore.Identity.IdentityResult> RemoveFromRoleAsync (TUser user, string role);
abstract member RemoveFromRoleAsync : 'User * string -> System.Threading.Tasks.Task<Microsoft.AspNetCore.Identity.IdentityResult>
override this.RemoveFromRoleAsync : 'User * string -> System.Threading.Tasks.Task<Microsoft.AspNetCore.Identity.IdentityResult>
Public Overridable Function RemoveFromRoleAsync (user As TUser, role As String) As Task(Of IdentityResult)

参数

user
TUser

要从命名角色中删除的用户。

role
String

要从中删除用户的角色的名称。

返回

表示 Task 异步操作的 ,包含 IdentityResult 操作的 。

适用于