DefaultModelMetadata Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
A default ModelMetadata implementation.
public ref class DefaultModelMetadata : Microsoft::AspNetCore::Mvc::ModelBinding::ModelMetadata
public class DefaultModelMetadata : Microsoft.AspNetCore.Mvc.ModelBinding.ModelMetadata
type DefaultModelMetadata = class
inherit ModelMetadata
Public Class DefaultModelMetadata
Inherits ModelMetadata
- Inheritance
Constructors
Properties
AdditionalValues |
Gets a collection of additional information about the model. |
Attributes |
Gets the set of attributes for the current instance. |
BinderModelName |
Gets the name of a model if specified explicitly using IModelNameProvider. |
BinderType |
Gets the Type of an IModelBinder of a model if specified explicitly using IBinderTypeProviderMetadata. |
BindingMetadata |
Gets the BindingMetadata for the current instance. |
BindingSource |
Gets a binder metadata for this model. |
BoundConstructor |
Gets ModelMetadata instance for a constructor of a record type that is used during binding and validation. |
BoundConstructor |
Gets ModelMetadata instance for a constructor of a record type that is used during binding and validation. (Inherited from ModelMetadata) |
BoundConstructorInvoker |
Gets a delegate that invokes the bound constructor BoundConstructor if non- |
BoundConstructorInvoker |
Gets a delegate that invokes the bound constructor BoundConstructor if non- |
BoundConstructorParameters |
Gets the collection of ModelMetadata instances for parameters on a BoundConstructor. This is only available when MetadataKind is Constructor. |
BoundConstructorParameters |
Gets the collection of ModelMetadata instances for parameters on a BoundConstructor. This is only available when MetadataKind is Constructor. (Inherited from ModelMetadata) |
ContainerMetadata |
Gets the metadata for ContainerType if this metadata is for a property;
|
ContainerMetadata |
Gets the metadata for ContainerType if this metadata is for a property;
|
ContainerType |
Gets the type containing the property if this metadata is for a property; |
ConvertEmptyStringToNull |
Gets a value indicating whether or not to convert an empty string value or one containing only whitespace
characters to |
DataTypeName |
Gets the name of the model's datatype. Overrides ModelType in some display scenarios. |
Description |
Gets the description of the model. |
DisplayFormatString |
Gets the format string (see https://msdn.microsoft.com/en-us/library/txafckwd.aspx) used to display the model. |
DisplayMetadata |
Gets the DisplayMetadata for the current instance. |
DisplayName |
Gets the display name of the model. |
EditFormatString |
Gets the format string (see https://msdn.microsoft.com/en-us/library/txafckwd.aspx) used to edit the model. |
ElementMetadata |
Gets the ModelMetadata for elements of ModelType if that Type implements IEnumerable. |
ElementType |
Gets the Type for elements of ModelType if that Type implements IEnumerable. (Inherited from ModelMetadata) |
EnumGroupedDisplayNamesAndValues |
Gets the ordered and grouped display names and values of all Enum values in UnderlyingOrModelType. |
EnumNamesAndValues |
Gets the names and values of all Enum values in UnderlyingOrModelType. |
HasNonDefaultEditFormat |
Gets a value indicating whether EditFormatString has a non- |
HasValidators |
Gets a value that indicates if the model, or one of its properties or elements, has associated validators. |
HasValidators |
Gets a value that indicates if the model, or one of its properties or elements, has associated validators. (Inherited from ModelMetadata) |
HideSurroundingHtml |
Gets a value indicating whether the "HiddenInput" display template should return
|
HtmlEncode |
Gets a value indicating whether the value should be HTML-encoded. |
Identity |
Gets the key for the current instance. (Inherited from ModelMetadata) |
IsBindingAllowed |
Gets a value indicating whether or not the model value can be bound by model binding. This is only applicable when the current instance represents a property. |
IsBindingRequired |
Gets a value indicating whether or not the model value is required by model binding. This is only applicable when the current instance represents a property. |
IsCollectionType |
Gets a value indicating whether or not ModelType is a collection type. (Inherited from ModelMetadata) |
IsComplexType |
Gets a value indicating whether ModelType is a complex type. (Inherited from ModelMetadata) |
IsEnum |
Gets a value indicating whether UnderlyingOrModelType is for an Enum. |
IsEnumerableType |
Gets a value indicating whether or not ModelType is an enumerable type. (Inherited from ModelMetadata) |
IsFlagsEnum |
Gets a value indicating whether UnderlyingOrModelType is for an Enum with an associated FlagsAttribute. |
IsNullableValueType |
Gets a value indicating whether or not ModelType is a Nullable<T>. (Inherited from ModelMetadata) |
IsReadOnly |
Gets a value indicating whether or not the model value is read-only. This is only applicable when the current instance represents a property. |
IsReferenceOrNullableType |
Gets a value indicating whether or not ModelType allows |
IsRequired |
Gets a value indicating whether or not the model value is required. This is only applicable when the current instance represents a property. |
MetadataKind |
Gets a value indicating the kind of metadata element represented by the current instance. (Inherited from ModelMetadata) |
ModelBindingMessageProvider |
Gets the ModelBindingMessageProvider instance. |
ModelType |
Gets the model type represented by the current instance. (Inherited from ModelMetadata) |
Name |
Gets the name of the parameter or property if this metadata is for a parameter or property;
|
NullDisplayText |
Gets the text to display when the model is |
Order |
Gets a value indicating where the current metadata should be ordered relative to other properties in its containing type. |
ParameterName |
Gets the name of the parameter if this metadata is for a parameter; |
Placeholder |
Gets the text to display as a placeholder value for an editor. By default, this is configured using Prompt. |
Properties |
Gets the collection of ModelMetadata instances for the model's properties. |
PropertyFilterProvider |
Gets the IPropertyFilterProvider, which can determine which properties should be model bound. |
PropertyGetter |
Gets a property getter delegate to get the property value from a model object. |
PropertyName |
Gets the name of the property if this metadata is for a property; |
PropertySetter |
Gets a property setter delegate to set the property value on a model object. |
PropertyValidationFilter |
Gets an IPropertyValidationFilter implementation that indicates whether this model should be
validated. If |
PropertyValidationFilter |
Gets an IPropertyValidationFilter implementation that indicates whether this model should be
validated. If |
ShowForDisplay |
Gets a value that indicates whether the property should be displayed in read-only views. |
ShowForEdit |
Gets a value that indicates whether the property should be displayed in editable views. |
SimpleDisplayProperty |
Gets a value which is the name of the property used to display the model. |
TemplateHint |
Gets a string used by the templating system to discover display-templates and editor-templates. Use UIHintAttribute to specify. |
UnderlyingOrModelType |
Gets the underlying type argument if ModelType inherits from Nullable<T>. Otherwise gets ModelType. (Inherited from ModelMetadata) |
ValidateChildren |
Gets a value that indicates whether properties or elements of the model should be validated. |
ValidationMetadata |
Gets the ValidationMetadata for the current instance. |
ValidatorMetadata |
Gets a collection of metadata items for validators. |
Methods
Equals(ModelMetadata) | (Inherited from ModelMetadata) |
Equals(Object) | (Inherited from ModelMetadata) |
GetDisplayName() |
Gets a display name for the model. (Inherited from ModelMetadata) |
GetHashCode() | (Inherited from ModelMetadata) |
GetMetadataForProperties(Type) |
Supplies metadata describing the properties of a Type. |
GetMetadataForProperties(Type) |
Supplies metadata describing the properties of a Type. (Inherited from ModelMetadata) |
GetMetadataForType(Type) |
Supplies metadata describing a Type. |
GetMetadataForType(Type) |
Supplies metadata describing a Type. (Inherited from ModelMetadata) |
Extension Methods
GetMetadataForProperty(IModelMetadataProvider, Type, String) |
Gets a ModelMetadata for property identified by the provided
|
GetModelExplorerForType(IModelMetadataProvider, Type, Object) |
Gets a ModelExplorer for the provided |