DbConfiguration.LoadConfiguration Method

 

Attempts to discover and load the DbConfiguration from the given assembly.

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

NameDescription
System_CAPS_pubmethodSystem_CAPS_staticLoadConfiguration(Assembly)

Attempts to discover and load the DbConfiguration from the given assembly. This method is intended to be used by tooling to ensure that the correct configuration is loaded into the app domain. Tooling should use this method before accessing the DependencyResolver property. If the tooling knows the DbContext type being used, then the LoadConfiguration method should be used since it gives a greater chance that the correct configuration will be found.

System_CAPS_pubmethodSystem_CAPS_staticLoadConfiguration(Type)

Attempts to discover and load the DbConfiguration associated with the given DbContext type. This method is intended to be used by tooling to ensure that the correct configuration is loaded into the app domain. Tooling should use this method before accessing the DependencyResolver property.


DbConfiguration.LoadConfiguration Method (Assembly)

Attempts to discover and load the DbConfiguration from the given assembly. This method is intended to be used by tooling to ensure that the correct configuration is loaded into the app domain. Tooling should use this method before accessing the DependencyResolver property. If the tooling knows the DbContext type being used, then the LoadConfiguration method should be used since it gives a greater chance that the correct configuration will be found.

public static void LoadConfiguration(
	Assembly assemblyHint
)

Parameters

assemblyHint
Type: System.Reflection.Assembly

An Assembly to use for configuration discovery.


DbConfiguration.LoadConfiguration Method (Type)

Attempts to discover and load the DbConfiguration associated with the given DbContext type. This method is intended to be used by tooling to ensure that the correct configuration is loaded into the app domain. Tooling should use this method before accessing the DependencyResolver property.

public static void LoadConfiguration(
	Type contextType
)

Parameters

contextType
Type: System.Type

A DbContext type to use for configuration discovery.