Share via


AssociatedMetadataProvider.GetMetadataForProperty Method (Func<Object>, Type, PropertyDescriptor)

Returns the metadata for the specified property using the container type and property descriptor.

Namespace:  System.Web.Mvc
Assembly:  System.Web.Mvc (in System.Web.Mvc.dll)

Syntax

'Declaration
Protected Overridable Function GetMetadataForProperty ( _
    modelAccessor As Func(Of Object), _
    containerType As Type, _
    propertyDescriptor As PropertyDescriptor _
) As ModelMetadata
protected virtual ModelMetadata GetMetadataForProperty(
    Func<Object> modelAccessor,
    Type containerType,
    PropertyDescriptor propertyDescriptor
)
protected:
virtual ModelMetadata^ GetMetadataForProperty(
    Func<Object^>^ modelAccessor, 
    Type^ containerType, 
    PropertyDescriptor^ propertyDescriptor
)

Parameters

  • containerType
    Type: System.Type
    The type of the container.

Return Value

Type: System.Web.Mvc.ModelMetadata
The metadata for the specified property.

See Also

Reference

AssociatedMetadataProvider Class

GetMetadataForProperty Overload

System.Web.Mvc Namespace