Share via


DefaultODataSerializerProvider.GetODataPayloadSerializer Method

Gets an ODataSerializer for the given model and type.

Namespace:  System.Web.Http.OData.Formatter.Serialization
Assembly:  System.Web.Http.OData (in System.Web.Http.OData.dll)

Syntax

'Declaration
Public Overrides Function GetODataPayloadSerializer ( _
    model As IEdmModel, _
    type As Type, _
    request As HttpRequestMessage _
) As ODataSerializer
'Usage
Dim instance As DefaultODataSerializerProvider 
Dim model As IEdmModel 
Dim type As Type 
Dim request As HttpRequestMessage 
Dim returnValue As ODataSerializer 

returnValue = instance.GetODataPayloadSerializer(model, _
    type, request)
public override ODataSerializer GetODataPayloadSerializer(
    IEdmModel model,
    Type type,
    HttpRequestMessage request
)
public:
virtual ODataSerializer^ GetODataPayloadSerializer(
    IEdmModel^ model, 
    Type^ type, 
    HttpRequestMessage^ request
) override
abstract GetODataPayloadSerializer : 
        model:IEdmModel * 
        type:Type * 
        request:HttpRequestMessage -> ODataSerializer  
override GetODataPayloadSerializer : 
        model:IEdmModel * 
        type:Type * 
        request:HttpRequestMessage -> ODataSerializer
public override function GetODataPayloadSerializer(
    model : IEdmModel, 
    type : Type, 
    request : HttpRequestMessage
) : ODataSerializer

Parameters

  • model
    Type: IEdmModel
    The EDM model.
  • type
    Type: System.Type
    The Type for which the serializer is being requested.

Return Value

Type: System.Web.Http.OData.Formatter.Serialization.ODataSerializer
The ODataSerializer for the given type.

See Also

Reference

DefaultODataSerializerProvider Class

System.Web.Http.OData.Formatter.Serialization Namespace