Share via


ODataPrimitiveSerializer.CreateODataPrimitiveValue Method

Definition

Creates an ODataPrimitiveValue for the object represented by graph.

public virtual Microsoft.OData.ODataPrimitiveValue CreateODataPrimitiveValue (object graph, Microsoft.OData.Edm.IEdmPrimitiveTypeReference primitiveType, Microsoft.AspNet.OData.Formatter.Serialization.ODataSerializerContext writeContext);
abstract member CreateODataPrimitiveValue : obj * Microsoft.OData.Edm.IEdmPrimitiveTypeReference * Microsoft.AspNet.OData.Formatter.Serialization.ODataSerializerContext -> Microsoft.OData.ODataPrimitiveValue
override this.CreateODataPrimitiveValue : obj * Microsoft.OData.Edm.IEdmPrimitiveTypeReference * Microsoft.AspNet.OData.Formatter.Serialization.ODataSerializerContext -> Microsoft.OData.ODataPrimitiveValue
Public Overridable Function CreateODataPrimitiveValue (graph As Object, primitiveType As IEdmPrimitiveTypeReference, writeContext As ODataSerializerContext) As ODataPrimitiveValue

Parameters

graph
Object

The primitive value.

primitiveType
IEdmPrimitiveTypeReference

The EDM primitive type of the value.

writeContext
ODataSerializerContext

The serializer write context.

Returns

The created ODataPrimitiveValue.

Applies to