Share via


IdentityDbContext<TUser,TRole,TKey,TUserClaim,TUserRole,TUserLogin,TRoleClaim,TUserToken> Class

Definition

Base class for the Entity Framework database context used for identity.

generic <typename TUser, typename TRole, typename TKey, typename TUserClaim, typename TUserRole, typename TUserLogin, typename TRoleClaim, typename TUserToken>
 where TUser : IdentityUser<TKey, TUserClaim, TUserRole, TUserLogin> where TRole : IdentityRole<TKey, TUserRole, TRoleClaim> where TKey : IEquatable<TKey> where TUserClaim : IdentityUserClaim<TKey> where TUserRole : IdentityUserRole<TKey> where TUserLogin : IdentityUserLogin<TKey> where TRoleClaim : IdentityRoleClaim<TKey> where TUserToken : IdentityUserToken<TKey>public ref class IdentityDbContext abstract : Microsoft::EntityFrameworkCore::DbContext
generic <typename TUser, typename TRole, typename TKey, typename TUserClaim, typename TUserRole, typename TUserLogin, typename TRoleClaim, typename TUserToken>
 where TUser : IdentityUser<TKey> where TRole : IdentityRole<TKey> where TKey : IEquatable<TKey> where TUserClaim : IdentityUserClaim<TKey> where TUserRole : IdentityUserRole<TKey> where TUserLogin : IdentityUserLogin<TKey> where TRoleClaim : IdentityRoleClaim<TKey> where TUserToken : IdentityUserToken<TKey>public ref class IdentityDbContext abstract : Microsoft::AspNetCore::Identity::EntityFrameworkCore::IdentityUserContext<TUser, TKey, TUserClaim, TUserLogin, TUserToken>
public abstract class IdentityDbContext<TUser,TRole,TKey,TUserClaim,TUserRole,TUserLogin,TRoleClaim,TUserToken> : Microsoft.EntityFrameworkCore.DbContext where TUser : IdentityUser<TKey,TUserClaim,TUserRole,TUserLogin> where TRole : IdentityRole<TKey,TUserRole,TRoleClaim> where TKey : IEquatable<TKey> where TUserClaim : IdentityUserClaim<TKey> where TUserRole : IdentityUserRole<TKey> where TUserLogin : IdentityUserLogin<TKey> where TRoleClaim : IdentityRoleClaim<TKey> where TUserToken : IdentityUserToken<TKey>
public abstract class IdentityDbContext<TUser,TRole,TKey,TUserClaim,TUserRole,TUserLogin,TRoleClaim,TUserToken> : Microsoft.AspNetCore.Identity.EntityFrameworkCore.IdentityUserContext<TUser,TKey,TUserClaim,TUserLogin,TUserToken> where TUser : IdentityUser<TKey> where TRole : IdentityRole<TKey> where TKey : IEquatable<TKey> where TUserClaim : IdentityUserClaim<TKey> where TUserRole : IdentityUserRole<TKey> where TUserLogin : IdentityUserLogin<TKey> where TRoleClaim : IdentityRoleClaim<TKey> where TUserToken : IdentityUserToken<TKey>
type IdentityDbContext<'User, 'Role, 'Key, 'UserClaim, 'UserRole, 'UserLogin, 'RoleClaim, 'UserToken (requires 'User :> IdentityUser<'Key, 'UserClaim, 'UserRole, 'UserLogin> and 'Role :> IdentityRole<'Key, 'UserRole, 'RoleClaim> and 'Key :> IEquatable<'Key> and 'UserClaim :> IdentityUserClaim<'Key> and 'UserRole :> IdentityUserRole<'Key> and 'UserLogin :> IdentityUserLogin<'Key> and 'RoleClaim :> IdentityRoleClaim<'Key> and 'UserToken :> IdentityUserToken<'Key>)> = class
    inherit DbContext
type IdentityDbContext<'User, 'Role, 'Key, 'UserClaim, 'UserRole, 'UserLogin, 'RoleClaim, 'UserToken (requires 'User :> IdentityUser<'Key> and 'Role :> IdentityRole<'Key> and 'Key :> IEquatable<'Key> and 'UserClaim :> IdentityUserClaim<'Key> and 'UserRole :> IdentityUserRole<'Key> and 'UserLogin :> IdentityUserLogin<'Key> and 'RoleClaim :> IdentityRoleClaim<'Key> and 'UserToken :> IdentityUserToken<'Key>)> = class
    inherit IdentityUserContext<'User, 'Key, 'UserClaim, 'UserLogin, 'UserToken (requires 'User :> IdentityUser<'Key> and 'Key :> IEquatable<'Key> and 'UserClaim :> IdentityUserClaim<'Key> and 'UserLogin :> IdentityUserLogin<'Key> and 'UserToken :> IdentityUserToken<'Key>)>
Public MustInherit Class IdentityDbContext(Of TUser, TRole, TKey, TUserClaim, TUserRole, TUserLogin, TRoleClaim, TUserToken)
Inherits DbContext
Public MustInherit Class IdentityDbContext(Of TUser, TRole, TKey, TUserClaim, TUserRole, TUserLogin, TRoleClaim, TUserToken)
Inherits IdentityUserContext(Of TUser, TKey, TUserClaim, TUserLogin, TUserToken)

Type Parameters

TUser

The type of user objects.

TRole

The type of role objects.

TKey

The type of the primary key for users and roles.

TUserClaim

The type of the user claim object.

TUserRole

The type of the user role object.

TUserLogin

The type of the user login object.

TRoleClaim

The type of the role claim object.

TUserToken

The type of the user token object.

Inheritance
IdentityDbContext<TUser,TRole,TKey,TUserClaim,TUserRole,TUserLogin,TRoleClaim,TUserToken>
Inheritance
IdentityDbContext<TUser,TRole,TKey,TUserClaim,TUserRole,TUserLogin,TRoleClaim,TUserToken>
Derived

Constructors

IdentityDbContext<TUser,TRole,TKey,TUserClaim,TUserRole,TUserLogin,TRoleClaim,TUserToken>()

Initializes a new instance of the class.

IdentityDbContext<TUser,TRole,TKey,TUserClaim,TUserRole,TUserLogin,TRoleClaim,TUserToken>(DbContextOptions)

Initializes a new instance of the class.

Properties

RoleClaims

Gets or sets the DbSet<TEntity> of role claims.

Roles

Gets or sets the DbSet<TEntity> of roles.

SchemaVersion

Gets the schema version used for versioning.

(Inherited from IdentityUserContext<TUser,TKey,TUserClaim,TUserLogin,TUserToken>)
UserClaims

Gets or sets the DbSet<TEntity> of User claims.

UserClaims

Gets or sets the DbSet<TEntity> of User claims.

(Inherited from IdentityUserContext<TUser,TKey,TUserClaim,TUserLogin,TUserToken>)
UserLogins

Gets or sets the DbSet<TEntity> of User logins.

UserLogins

Gets or sets the DbSet<TEntity> of User logins.

(Inherited from IdentityUserContext<TUser,TKey,TUserClaim,TUserLogin,TUserToken>)
UserRoles

Gets or sets the DbSet<TEntity> of User roles.

Users

Gets or sets the DbSet<TEntity> of Users.

Users

Gets or sets the DbSet<TEntity> of Users.

(Inherited from IdentityUserContext<TUser,TKey,TUserClaim,TUserLogin,TUserToken>)
UserTokens

Gets or sets the DbSet<TEntity> of User tokens.

UserTokens

Gets or sets the DbSet<TEntity> of User tokens.

(Inherited from IdentityUserContext<TUser,TKey,TUserClaim,TUserLogin,TUserToken>)

Methods

OnModelCreating(ModelBuilder)

Configures the schema needed for the identity framework.

Applies to