Show / Hide Table of Contents

Class IdentityUser

Represents a user in the identity system.

Inheritance
Object
Microsoft.AspNetCore.Identity.IdentityUser<System.Guid>
IdentityUser
MultitenantUser
Inherited Members
IdentityUser<Guid>.ToString()
IdentityUser<Guid>.Id
IdentityUser<Guid>.UserName
Microsoft.AspNetCore.Identity.IdentityUser<System.Guid>.NormalizedUserName
IdentityUser<Guid>.Email
Microsoft.AspNetCore.Identity.IdentityUser<System.Guid>.NormalizedEmail
Microsoft.AspNetCore.Identity.IdentityUser<System.Guid>.EmailConfirmed
Microsoft.AspNetCore.Identity.IdentityUser<System.Guid>.PasswordHash
Microsoft.AspNetCore.Identity.IdentityUser<System.Guid>.SecurityStamp
IdentityUser<Guid>.ConcurrencyStamp
Microsoft.AspNetCore.Identity.IdentityUser<System.Guid>.PhoneNumber
Microsoft.AspNetCore.Identity.IdentityUser<System.Guid>.PhoneNumberConfirmed
Microsoft.AspNetCore.Identity.IdentityUser<System.Guid>.TwoFactorEnabled
Microsoft.AspNetCore.Identity.IdentityUser<System.Guid>.LockoutEnd
IdentityUser<Guid>.LockoutEnabled
Microsoft.AspNetCore.Identity.IdentityUser<System.Guid>.AccessFailedCount
Object.Equals(Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
Namespace: IRM.AspNetCore.Identity
Assembly: IRM.AspNetCore.Identity.EntityFrameworkCore.dll
Syntax
[Stream("User")]
public class IdentityUser : IdentityUser<Guid>, IValidUser, ILocalUser, IUser, IUserIdentifiers, IUniqueIdentifier, IHaveEmail, IEventAggregate, IHaveClaims, IEventSourced

Constructors

IdentityUser()

Creates a new instance of IdentityUser.

Declaration
public IdentityUser()

Properties

Claims

Navigation property for the claims this user possesses.

Declaration
public virtual ICollection<IdentityUserClaim<Guid>> Claims { get; set; }
Property Value
System.Collections.Generic.ICollection<Microsoft.AspNetCore.Identity.IdentityUserClaim<System.Guid>>

IsSystemUser

Gets or sets if the user is a system or not.

Declaration
public bool IsSystemUser { get; set; }
Property Value
Boolean

true if the user is a system; false if the user is human.

Implements
IUserIdentifiers.IsSystemUser

LastSignedIn

Gets or sets the date and time, in UTC, when the user last signed in.

Declaration
public DateTime? LastSignedIn { get; set; }
Property Value
System.Nullable<System.DateTime>

Implements
IUser.LastSignedIn
Remarks

A missing value means the user has not signed in yet.

PasswordLastChanged

Gets or sets the date and time, in UTC, when the user last changed password.

Declaration
public DateTimeOffset? PasswordLastChanged { get; set; }
Property Value
System.Nullable<System.DateTimeOffset>

Implements
ILocalUser.PasswordLastChanged
Remarks

A missing value means the user has not any password set yet or that the user must change password next time when signing in.

PasswordNeverExpires

Gets or sets if the password never expires and therefor are never forced to be changed.

Declaration
public bool PasswordNeverExpires { get; set; }
Property Value
Boolean

Implements
ILocalUser.PasswordNeverExpires

ValidFrom

Gets or sets the System.DateTime, in UTC, from which the user is valid to sign-in.

Declaration
public DateTime ValidFrom { get; set; }
Property Value
System.DateTime

Implements
IValidUser.ValidFrom

ValidTo

Gets or sets the System.DateTime, in UTC, on which the user is valid to sign-in.

Declaration
public DateTime? ValidTo { get; set; }
Property Value
System.Nullable<System.DateTime>

Implements
IValidUser.ValidTo

Methods

GetClaims(String)

Gets a collection of claims for this user.

Declaration
public virtual IEnumerable<Claim> GetClaims(string userNameClaimType = "preferred_username")
Parameters
String userNameClaimType

Returns
IEnumerable<System.Security.Claims.Claim>

A collection of claims.

Implements
IUser.GetClaims(String)

IsValid()

Gets if the user is valid to sign-in.

Declaration
public bool IsValid()
Returns
Boolean

true if the user is valid to sign-in; otherwise false.

Implements
IValidUser.IsValid()

RaiseEvent(IEvent)

Adds an event to the aggregate. The added event will be handled if an IEventSourceRepository is configured.

Declaration
public virtual void RaiseEvent(IEvent event)
Parameters
IEvent event

The IEvent to add to the aggregate.

Implements
IEventAggregate.RaiseEvent(IEvent)

Explicit Interface Implementations

IHaveClaims.GetClaims()

Declaration
IEnumerable<Claim> IHaveClaims.GetClaims()
Returns
IEnumerable<System.Security.Claims.Claim>

Implements
IHaveClaims.GetClaims()

IEventSourced.ClearUncommittedEvents()

Declaration
void IEventSourced.ClearUncommittedEvents()
Implements
IEventSourced.ClearUncommittedEvents()

IEventSourced.GetUncommittedEvents()

Declaration
IEnumerable<IEvent> IEventSourced.GetUncommittedEvents()
Returns
IEnumerable<IEvent>

Implements
IEventSourced.GetUncommittedEvents()

IEventSourced.LoadFromEvents(IEnumerable<IEvent>)

Declaration
void IEventSourced.LoadFromEvents(IEnumerable<IEvent> events)
Parameters
IEnumerable<IEvent> events

Implements
IEventSourced.LoadFromEvents(IEnumerable<IEvent>)

IEventSourced.Version

Declaration
int IEventSourced.Version { get; set; }
Returns
System.Int32

Implements
IEventSourced.Version
Back to top Generated by DocFX