CachedAssociatedMetadataProvider<TModelMetadata>.CreateMetadata 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
在衍生類別中覆寫時,建立屬性的快取模型中繼資料。
protected override sealed 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 NotOverridable 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
容器型別。
- modelType
- Type
模型型別。
- propertyName
- String
屬性名稱。
傳回
屬性的快取模型中繼資料。