Class ModelsBuilderModeValidator
Validates whether the ModelsBuilder mode is not set to InMemoryAuto when in development runtime mode and set to Nothing when in production runtime mode.
Inheritance
System.Object
Namespace: Umbraco.Cms.Infrastructure.Runtime.RuntimeModeValidators
Assembly: Umbraco.Infrastructure.dll
Syntax
public class ModelsBuilderModeValidator : IRuntimeModeValidator
Constructors
View SourceModelsBuilderModeValidator(IOptionsMonitor<ModelsBuilderSettings>)
Initializes a new instance of the ModelsBuilderModeValidator class.
Declaration
public ModelsBuilderModeValidator(IOptionsMonitor<ModelsBuilderSettings> modelsBuilderSettings)
Parameters
Type | Name | Description |
---|---|---|
IOptionsMonitor<ModelsBuilderSettings> | modelsBuilderSettings | The models builder settings. |
Methods
View SourceValidate(RuntimeMode, out String)
Validates configuration based on the specified runtimeMode
.
Declaration
public bool Validate(RuntimeMode runtimeMode, out string validationErrorMessage)
Parameters
Type | Name | Description |
---|---|---|
RuntimeMode | runtimeMode | The runtime mode. |
System.String | validationErrorMessage | The validation error message. |
Returns
Type | Description |
---|---|
System.Boolean |
|