ModelMetadataProvider.GetMetadataForType Method
Gets the metadata for the specified model accessor and model type.
Namespace: System.Web.Http.Metadata
Assembly: System.Web.Http (in System.Web.Http.dll)
Syntax
'Declaration
Public MustOverride Function GetMetadataForType ( _
modelAccessor As Func(Of Object), _
modelType As Type _
) As ModelMetadata
'Usage
Dim instance As ModelMetadataProvider
Dim modelAccessor As Func(Of Object)
Dim modelType As Type
Dim returnValue As ModelMetadata
returnValue = instance.GetMetadataForType(modelAccessor, _
modelType)
public abstract ModelMetadata GetMetadataForType(
Func<Object> modelAccessor,
Type modelType
)
public:
virtual ModelMetadata^ GetMetadataForType(
Func<Object^>^ modelAccessor,
Type^ modelType
) abstract
abstract GetMetadataForType :
modelAccessor:Func<Object> *
modelType:Type -> ModelMetadata
public abstract function GetMetadataForType(
modelAccessor : Func<Object>,
modelType : Type
) : ModelMetadata
Parameters
modelAccessor
Type: System.Func<Object>The model accessor.
modelType
Type: System.TypeThe type of the mode.
Return Value
Type: System.Web.Http.Metadata.ModelMetadata
The metadata.