EmptyModelMetadataProvider.CreateMetadata 方法

定义

创建 ModelMetadata 类的新实例。

protected override System.Web.Mvc.ModelMetadata CreateMetadata (System.Collections.Generic.IEnumerable<Attribute> attributes, Type containerType, Func<object> modelAccessor, Type modelType, string propertyName);
override this.CreateMetadata : seq<Attribute> * Type * Func<obj> * Type * string -> System.Web.Mvc.ModelMetadata
Protected Overrides Function CreateMetadata (attributes As IEnumerable(Of Attribute), containerType As Type, modelAccessor As Func(Of Object), modelType As Type, propertyName As String) As ModelMetadata

参数

attributes
IEnumerable<Attribute>

属性。

containerType
Type

容器的类型。

modelAccessor
Func<Object>

模型访问器。

modelType
Type

模型的类型。

propertyName
String

模型的名称。

返回

ModelMetadata 类的新实例。

适用于