ModelStateEntry Class¶
An entry in a Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateDictionary.
- Namespace
Microsoft.AspNetCore.Mvc.ModelBinding- Assemblies
- Microsoft.AspNetCore.Mvc.Abstractions
Syntax¶
public abstract class ModelStateEntry
-
class
Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateEntry
Properties¶
-
Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateEntry.AttemptedValue¶ Gets the set of values contained in
Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateEntry.RawValue, joined into a comma-separated string.Return type: System.String public string AttemptedValue { get; set; }
-
Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateEntry.Children¶ Gets the
Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateEntryvalues for sub-properties.Return type: System.Collections.Generic.IReadOnlyList<Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateEntry> public abstract IReadOnlyList<ModelStateEntry> Children { get; }
-
Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateEntry.Errors¶ Gets the
Microsoft.AspNetCore.Mvc.ModelBinding.ModelErrorCollectionfor this entry.Return type: Microsoft.AspNetCore.Mvc.ModelBinding.ModelErrorCollection public ModelErrorCollection Errors { get; }
-
Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateEntry.IsContainerNode¶ Gets a value that determines if the current instance of
Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateEntryis a container node. Container nodes represent prefix nodes that aren’t explicitly added to theMicrosoft.AspNetCore.Mvc.ModelBinding.ModelStateDictionary.Return type: System.Boolean public abstract bool IsContainerNode { get; }
-
Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateEntry.RawValue¶ Gets the raw value from the request associated with this entry.
Return type: System.Object public object RawValue { get; set; }
-
Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateEntry.ValidationState¶ Gets or sets the
Microsoft.AspNetCore.Mvc.ModelBinding.ModelValidationStatefor this entry.Return type: Microsoft.AspNetCore.Mvc.ModelBinding.ModelValidationState public ModelValidationState ValidationState { get; set; }
-
Methods¶
-
GetModelStateForProperty(System.String)¶ Gets the
Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateEntryfor a sub-property with the specified <em>propertyName</em>.Arguments: propertyName (System.String) – The property name to lookup. Return type: Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateEntry Returns: The Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateEntryif a sub-property was found; otherwise <code>null</code>.public abstract ModelStateEntry GetModelStateForProperty(string propertyName)
-