Share via


IConventionSetPlugin Interface

Definition

A service on the EF internal service provider that allows extensions to customize the ConventionSet being used.

This type is typically used by extensions. It is generally not used in application code.

public interface IConventionSetPlugin
type IConventionSetPlugin = interface
Public Interface IConventionSetPlugin

Remarks

Database providers should implement IProviderConventionSetBuilder. This service is intended only for non-provider extensions that need to customize conventions.

The service lifetime is Scoped and multiple registrations are allowed. This means that each DbContext instance will use its own set of instances of this service. The implementations may depend on other services registered with any lifetime. The implementations do not need to be thread-safe.

See Model building conventions for more information and examples.

Methods

ModifyConventions(ConventionSet)

Called to customize or otherwise modify the given convention set.

Applies to