MvcOptions Class

Summary

Provides programmatic configuration for the MVC framework.

Syntax

public class MvcOptions

GitHub

View on GitHub

class Microsoft.AspNet.Mvc.MvcOptions

Constructors

Microsoft.AspNet.Mvc.MvcOptions.MvcOptions()
public MvcOptions()

Properties

Conventions()

Gets a list of [Microsoft.AspNet.Mvc.ApplicationModels.IApplicationModelConvention](Microsoft.AspNet.Mvc.ApplicationModels.IApplicationModelConvention.yml) instances that will be applied to the [Microsoft.AspNet.Mvc.ApplicationModels.ApplicationModel](Microsoft.AspNet.Mvc.ApplicationModels.ApplicationModel.yml) when discovering actions.

Return type:System.Collections.Generic.IList{Microsoft.AspNet.Mvc.ApplicationModels.IApplicationModelConvention}
public IList<IApplicationModelConvention> Conventions { get; }
Filters()

Gets a list of [Microsoft.AspNet.Mvc.IFilter]() which are used to construct filters that apply to all actions.

Return type:System.Collections.Generic.ICollection{Microsoft.AspNet.Mvc.IFilter}
public ICollection<IFilter> Filters { get; }
InputFormatters()

Gets a list of [Microsoft.AspNet.Mvc.IInputFormatter]()s that are used by this application.

Return type:System.Collections.Generic.IList{Microsoft.AspNet.Mvc.IInputFormatter}
public IList<IInputFormatter> InputFormatters { get; }
MaxModelValidationErrors()

Gets or sets the maximum number of validation errors that are allowed by this application before further errors are ignored.

Return type:System.Int32
public int MaxModelValidationErrors { get; set; }
ModelBinders()

Gets a list of [Microsoft.AspNet.Mvc.ModelBinding.IModelBinder]()s used by this application.

Return type:System.Collections.Generic.IList{Microsoft.AspNet.Mvc.ModelBinding.IModelBinder}
public IList<IModelBinder> ModelBinders { get; }
ModelMetadataDetailsProviders()

Gets a list of [Microsoft.AspNet.Mvc.ModelBinding.Metadata.IMetadataDetailsProvider](Microsoft.AspNet.Mvc.ModelBinding.Metadata.IMetadataDetailsProvider.yml) instances that will be used to create [Microsoft.AspNet.Mvc.ModelBinding.ModelMetadata]() instances.

Return type:System.Collections.Generic.IList{Microsoft.AspNet.Mvc.ModelBinding.Metadata.IMetadataDetailsProvider}
public IList<IMetadataDetailsProvider> ModelMetadataDetailsProviders { get; }
ModelValidatorProviders()

Gets a list of [Microsoft.AspNet.Mvc.ModelBinding.Validation.IModelValidatorProvider]()s used by this application.

Return type:System.Collections.Generic.IList{Microsoft.AspNet.Mvc.ModelBinding.Validation.IModelValidatorProvider}
public IList<IModelValidatorProvider> ModelValidatorProviders { get; }
OutputFormatters()

Gets a list of [Microsoft.AspNet.Mvc.IOutputFormatter]()s that are used by this application.

Return type:System.Collections.Generic.IList{Microsoft.AspNet.Mvc.IOutputFormatter}
public IList<IOutputFormatter> OutputFormatters { get; }
RespectBrowserAcceptHeader()

Gets or sets the flag which causes content negotiation to ignore Accept header when it contains the media type /. <see langword=”false” /> by default.

Return type:System.Boolean
public bool RespectBrowserAcceptHeader { get; set; }
ValidationExcludeFilters()

Gets a list of [Microsoft.AspNet.Mvc.ModelBinding.Validation.IExcludeTypeValidationFilter](Microsoft.AspNet.Mvc.ModelBinding.Validation.IExcludeTypeValidationFilter.yml)s that are used by this application.

Return type:System.Collections.Generic.IList{Microsoft.AspNet.Mvc.ModelBinding.Validation.IExcludeTypeValidationFilter}
public IList<IExcludeTypeValidationFilter> ValidationExcludeFilters { get; }
ValueProviderFactories()

Gets a list of [Microsoft.AspNet.Mvc.ModelBinding.IValueProviderFactory]() used by this application.

Return type:System.Collections.Generic.IList{Microsoft.AspNet.Mvc.ModelBinding.IValueProviderFactory}
public IList<IValueProviderFactory> ValueProviderFactories { get; }