IStartupValidator Interface
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.
Caution
Implement IAsyncStartupValidator instead.
Provides synchronous options validation during host startup.
public interface class IStartupValidator
[System.Obsolete("Implement IAsyncStartupValidator instead.", DiagnosticId="SYSLIB0066", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
public interface IStartupValidator
public interface IStartupValidator
[<System.Obsolete("Implement IAsyncStartupValidator instead.", DiagnosticId="SYSLIB0066", UrlFormat="https://aka.ms/dotnet-warnings/{0}")>]
type IStartupValidator = interface
type IStartupValidator = interface
Public Interface IStartupValidator
- Attributes
Remarks
Options are enabled to be validated during startup by calling ValidateOnStart<TOptions>(OptionsBuilder<TOptions>). This interface is retained for compatibility. New startup validators should implement and register IAsyncStartupValidator instead. When migrating, replace the obsolete registration rather than registering a custom validator under both startup contracts.
Methods
| Name | Description |
|---|---|
| Validate() |
Validates options during host startup. |