DbModelBuilder.Entity(Of TEntityType) Method

Entity Framework 5.0

Registers an entity type as part of the model and returns an object that can be used to configure the entity. This method can be called multiple times for the same entity to perform multiple lines of configuration.

Namespace:  System.Data.Entity
Assembly:  EntityFramework (in EntityFramework.dll)

Public Overridable Function Entity(Of TEntityType As Class) As EntityTypeConfiguration(Of TEntityType)
Dim instance As DbModelBuilder 
Dim returnValue As EntityTypeConfiguration(Of TEntityType)

returnValue = instance.Entity()

Type Parameters


The type to be registered or configured.

Return Value

Type: System.Data.Entity.ModelConfiguration.EntityTypeConfiguration(Of TEntityType)
The configuration object for the specified entity type.