UserManager<TUser>.ReplaceClaimAsync(TUser, Claim, Claim) Method

Definition

Replaces the given claim on the specified user with the newClaim

public:
 virtual System::Threading::Tasks::Task<Microsoft::AspNetCore::Identity::IdentityResult ^> ^ ReplaceClaimAsync(TUser user, System::Security::Claims::Claim ^ claim, System::Security::Claims::Claim ^ newClaim);
public virtual System.Threading.Tasks.Task<Microsoft.AspNetCore.Identity.IdentityResult> ReplaceClaimAsync (TUser user, System.Security.Claims.Claim claim, System.Security.Claims.Claim newClaim);
abstract member ReplaceClaimAsync : 'User * System.Security.Claims.Claim * System.Security.Claims.Claim -> System.Threading.Tasks.Task<Microsoft.AspNetCore.Identity.IdentityResult>
override this.ReplaceClaimAsync : 'User * System.Security.Claims.Claim * System.Security.Claims.Claim -> System.Threading.Tasks.Task<Microsoft.AspNetCore.Identity.IdentityResult>
Public Overridable Function ReplaceClaimAsync (user As TUser, claim As Claim, newClaim As Claim) As Task(Of IdentityResult)

Parameters

user
TUser

The user to replace the claim on.

claim
Claim

The claim to replace.

newClaim
Claim

The new claim to replace the existing claim with.

Returns

The Task that represents the asynchronous operation, containing the IdentityResult of the operation.

Applies to