CachedAssociatedMetadataProvider<TModelMetadata>.GetMetadataForProperty Method (Func<Object>, Type, String)
Returns the metadata for the specified property.
Namespace: System.Web.Mvc
Assembly: System.Web.Mvc (in System.Web.Mvc.dll)
Syntax
'Declaration
Public Overrides NotOverridable Function GetMetadataForProperty ( _
modelAccessor As Func(Of Object), _
containerType As Type, _
propertyName As String _
) As ModelMetadata
'Usage
Dim instance As CachedAssociatedMetadataProvider
Dim modelAccessor As Func(Of Object)
Dim containerType As Type
Dim propertyName As String
Dim returnValue As ModelMetadata
returnValue = instance.GetMetadataForProperty(modelAccessor, _
containerType, propertyName)
public override sealed ModelMetadata GetMetadataForProperty(
Func<Object> modelAccessor,
Type containerType,
string propertyName
)
public:
virtual ModelMetadata^ GetMetadataForProperty(
Func<Object^>^ modelAccessor,
Type^ containerType,
String^ propertyName
) override sealed
abstract GetMetadataForProperty :
modelAccessor:Func<Object> *
containerType:Type *
propertyName:string -> ModelMetadata
override GetMetadataForProperty :
modelAccessor:Func<Object> *
containerType:Type *
propertyName:string -> ModelMetadata
public override final function GetMetadataForProperty(
modelAccessor : Func<Object>,
containerType : Type,
propertyName : String
) : ModelMetadata
Parameters
modelAccessor
Type: System.Func<Object>The model accessor.
containerType
Type: System.TypeThe container type.
propertyName
Type: System.StringThe property name.
Return Value
Type: System.Web.Mvc.ModelMetadata
The metadata for the specified property.
See Also
Reference
CachedAssociatedMetadataProvider<TModelMetadata> Class