IEntityTypeConfiguration<TEntity> IEntityTypeConfiguration<TEntity> IEntityTypeConfiguration<TEntity> Interface


Allows configuration for an entity type to be factored into a separate class, rather than in-line in OnModelCreating(ModelBuilder). Implement this interface, applying configuration for the entity in the Configure(EntityTypeBuilder<TEntity>) method, and then apply the configuration to the model using ApplyConfiguration<TEntity>(IEntityTypeConfiguration<TEntity>) in OnModelCreating(ModelBuilder).

public interface IEntityTypeConfiguration<TEntity> where TEntity : class
type IEntityTypeConfiguration<'Entity (requires 'Entity : null)> = interface
Public Interface IEntityTypeConfiguration(Of TEntity)

Type Parameters


The entity type to be configured.


Configure(EntityTypeBuilder<TEntity>) Configure(EntityTypeBuilder<TEntity>) Configure(EntityTypeBuilder<TEntity>)

Configures the entity of type TEntity.

Applies to