DbMigrationsConfiguration.SetHistoryContextFactory 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.
Adds a new factory for creating HistoryContext instances to be used for a given database provider.
public void SetHistoryContextFactory (string providerInvariantName, Func<System.Data.Common.DbConnection,string,System.Data.Entity.Migrations.History.HistoryContext> factory);
member this.SetHistoryContextFactory : string * Func<System.Data.Common.DbConnection, string, System.Data.Entity.Migrations.History.HistoryContext> -> unit
Public Sub SetHistoryContextFactory (providerInvariantName As String, factory As Func(Of DbConnection, String, HistoryContext))
Parameters
- providerInvariantName
- String
Name of the database provider to set the SQL generator for.
- factory
- Func<DbConnection,String,HistoryContext>
A factory for creating HistoryContext instances for a given DbConnection and String representing the default schema.
Applies to
Met ons samenwerken op GitHub
De bron voor deze inhoud vindt u op GitHub, waar u ook problemen en pull-aanvragen kunt maken en controleren. Bekijk onze gids voor inzenders voor meer informatie.
Entity Framework