diff --git a/src/Microsoft.AspNet.Mvc.ModelBinding/ModelBindingContext.cs b/src/Microsoft.AspNet.Mvc.ModelBinding/ModelBindingContext.cs
index 1914f8cefe..a5870a7225 100644
--- a/src/Microsoft.AspNet.Mvc.ModelBinding/ModelBindingContext.cs
+++ b/src/Microsoft.AspNet.Mvc.ModelBinding/ModelBindingContext.cs
@@ -8,6 +8,9 @@ using Microsoft.AspNet.Http;
namespace Microsoft.AspNet.Mvc.ModelBinding
{
+ ///
+ /// A context that contains operating information for model binding and validation.
+ ///
public class ModelBindingContext
{
private string _modelName;
@@ -15,12 +18,21 @@ namespace Microsoft.AspNet.Mvc.ModelBinding
private Dictionary _propertyMetadata;
private ModelValidationNode _validationNode;
+ ///
+ /// Initializes a new instance of the class.
+ ///
public ModelBindingContext()
{
}
- // copies certain values that won't change between parent and child objects,
- // e.g. ValueProvider, ModelState
+ ///
+ /// Initializes a new instance of the class using the
+ /// .
+ //
+ ///
+ /// This constructor copies certain values that won't change between parent and child objects,
+ /// e.g. ValueProvider, ModelState
+ ///
public ModelBindingContext(ModelBindingContext bindingContext)
{
if (bindingContext != null)
@@ -34,6 +46,12 @@ namespace Microsoft.AspNet.Mvc.ModelBinding
}
}
+ ///
+ /// Gets or sets the model associated with this context.
+ ///
+ ///
+ /// The property must be set to access this property.
+ ///
public object Model
{
get
@@ -48,8 +66,15 @@ namespace Microsoft.AspNet.Mvc.ModelBinding
}
}
+ ///
+ /// Gets or sets the metadata for the model associated with this context.
+ ///
public ModelMetadata ModelMetadata { get; set; }
+ ///
+ /// Gets or sets the name of the model. This property is used as a key for looking up values in
+ /// during model binding.
+ ///
public string ModelName
{
get
@@ -63,6 +88,10 @@ namespace Microsoft.AspNet.Mvc.ModelBinding
set { _modelName = value; }
}
+ ///
+ /// Gets or sets the used to capture values
+ /// for properties in the object graph of the model when binding.
+ ///
public ModelStateDictionary ModelState
{
get
@@ -76,6 +105,12 @@ namespace Microsoft.AspNet.Mvc.ModelBinding
set { _modelState = value; }
}
+ ///
+ /// Gets the type of the model.
+ ///
+ ///
+ /// The property must be set to access this property.
+ ///
public Type ModelType
{
get
@@ -85,34 +120,43 @@ namespace Microsoft.AspNet.Mvc.ModelBinding
}
}
+ ///
+ /// Gets or sets a value that indicates whether the binder should use an empty prefix to look up
+ /// values in when no values are found using the
+ /// prefix.
+ ///
public bool FallbackToEmptyPrefix { get; set; }
+ ///
+ /// Gets or sets the for the current request.
+ ///
public HttpContext HttpContext { get; set; }
- public IValueProvider ValueProvider
- {
- get;
- set;
- }
+ ///
+ /// Gets or sets the associated with this context.
+ ///
+ public IValueProvider ValueProvider { get; set; }
- public IModelBinder ModelBinder
- {
- get;
- set;
- }
+ ///
+ /// Gets or sets the associated with this context.
+ ///
+ public IModelBinder ModelBinder { get; set; }
- public IModelMetadataProvider MetadataProvider
- {
- get;
- set;
- }
+ ///
+ /// Gets or sets the associated with this context.
+ ///
+ public IModelMetadataProvider MetadataProvider { get; set; }
- public IEnumerable ValidatorProviders
- {
- get;
- set;
- }
+ ///
+ /// Gets or sets the sequence of instances used for model validation
+ /// with this context.
+ ///
+ public IEnumerable ValidatorProviders { get; set; }
+ ///
+ /// Gets a dictionary of property name to instances for
+ ///
+ ///
public IDictionary PropertyMetadata
{
get
@@ -128,6 +172,10 @@ namespace Microsoft.AspNet.Mvc.ModelBinding
}
}
+ ///
+ /// Gets or sets the instance used as a container for
+ /// validation information.
+ ///
public ModelValidationNode ValidationNode
{
get