IModelValidator Interface

Definition

Validates a model after it is built.

The service lifetime is Singleton. This means a single instance is used by many DbContext instances. The implementation must be thread-safe. This service cannot depend on services registered as Scoped.

public interface IModelValidator
type IModelValidator = interface
Public Interface IModelValidator
Derived

Methods

Validate(IModel)

Validates a model, throwing an exception if any errors are found.

Validate(IModel, IDiagnosticsLogger<DbLoggerCategory.Model>)

Validates a model, throwing an exception if any errors are found.

Applies to