ModelConfigurationBuilder.CreateModelBuilder(ModelDependencies) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Creates the configured ModelBuilder used to create the model. This is done automatically when using OnModelCreating(ModelBuilder); this method allows it to be run explicitly in cases where the automatic execution is not possible.
public virtual Microsoft.EntityFrameworkCore.ModelBuilder CreateModelBuilder (Microsoft.EntityFrameworkCore.Infrastructure.ModelDependencies? modelDependencies);
abstract member CreateModelBuilder : Microsoft.EntityFrameworkCore.Infrastructure.ModelDependencies -> Microsoft.EntityFrameworkCore.ModelBuilder
override this.CreateModelBuilder : Microsoft.EntityFrameworkCore.Infrastructure.ModelDependencies -> Microsoft.EntityFrameworkCore.ModelBuilder
Public Overridable Function CreateModelBuilder (modelDependencies As ModelDependencies) As ModelBuilder
Parameters
- modelDependencies
- ModelDependencies
The dependencies object used during model building.
Returns
The configured ModelBuilder.
Remarks
See Pre-convention model building in EF Core for more information and examples.
Applies to
Entity Framework
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for