Table of Contents

Class ModelState

Namespace
System.Web.Http.ModelBinding
Assembly
System.Web.Http.dll

Encapsulates the state of model binding to a property of an action-method argument, or to the argument itself.

public class ModelState
Inheritance
ModelState
Inherited Members

Constructors

ModelState()

Initializes a new instance of the ModelState class.

public ModelState()

Properties

Errors

Gets a ModelErrorCollection object that contains any errors that occurred during model binding.

public ModelErrorCollection Errors { get; }

Property Value

ModelErrorCollection

The model state errors.

Value

Gets a ValueProviderResult object that encapsulates the value that was being bound during model binding.

public ValueProviderResult Value { get; set; }

Property Value

ValueProviderResult

The model state value.