Partager via


DataAnnotationsModelMetadataProvider.CreateMetadataPrototype Method

Creates the metadata for the specified property.

Namespace:  System.Web.Http.Metadata.Providers
Assembly:  System.Web.Http (in System.Web.Http.dll)

Syntax

'Declaration
Protected Overrides Function CreateMetadataPrototype ( _
    attributes As IEnumerable(Of Attribute), _
    containerType As Type, _
    modelType As Type, _
    propertyName As String _
) As CachedDataAnnotationsModelMetadata
'Usage
Dim attributes As IEnumerable(Of Attribute)
Dim containerType As Type 
Dim modelType As Type 
Dim propertyName As String 
Dim returnValue As CachedDataAnnotationsModelMetadata 

returnValue = Me.CreateMetadataPrototype(attributes, _
    containerType, modelType, propertyName)
protected override CachedDataAnnotationsModelMetadata CreateMetadataPrototype(
    IEnumerable<Attribute> attributes,
    Type containerType,
    Type modelType,
    string propertyName
)
protected:
virtual CachedDataAnnotationsModelMetadata^ CreateMetadataPrototype(
    IEnumerable<Attribute^>^ attributes, 
    Type^ containerType, 
    Type^ modelType, 
    String^ propertyName
) override
abstract CreateMetadataPrototype : 
        attributes:IEnumerable<Attribute> * 
        containerType:Type * 
        modelType:Type * 
        propertyName:string -> CachedDataAnnotationsModelMetadata  
override CreateMetadataPrototype : 
        attributes:IEnumerable<Attribute> * 
        containerType:Type * 
        modelType:Type * 
        propertyName:string -> CachedDataAnnotationsModelMetadata
protected override function CreateMetadataPrototype(
    attributes : IEnumerable<Attribute>, 
    containerType : Type, 
    modelType : Type, 
    propertyName : String
) : CachedDataAnnotationsModelMetadata

Parameters

  • containerType
    Type: System.Type

    The type of the container.

Return Value

Type: System.Web.Http.Metadata.Providers.CachedDataAnnotationsModelMetadata
The metadata for the property.

See Also

Reference

DataAnnotationsModelMetadataProvider Class

System.Web.Http.Metadata.Providers Namespace