Share via


ODataMessageReaderSettings.EnableWcfDataServicesClientBehavior Method (Func<IEdmType, String, IEdmType>)

 

Enables the same behavior that the WCF Data Services client has. Also, lets the user set the values for custom data namespace and type scheme.

Namespace:   Microsoft.OData.Core
Assembly:  Microsoft.OData.Core (in Microsoft.OData.Core.dll)

Syntax

public void EnableWcfDataServicesClientBehavior(
    Func<IEdmType, string, IEdmType> typeResolver
)
public:
void EnableWcfDataServicesClientBehavior(
    Func<IEdmType^, String^, IEdmType^>^ typeResolver
)
member EnableWcfDataServicesClientBehavior : 
        typeResolver:Func<IEdmType, string, IEdmType> -> unit
Public Sub EnableWcfDataServicesClientBehavior (
    typeResolver As Func(Of IEdmType, String, IEdmType)
)

Parameters

  • typeResolver
    Type: System.Func<IEdmType, String, IEdmType>

    Custom type resolver which takes both expected type and type name. This function is used instead of the IEdmModel.FindType if it's specified. The first parameter to the function is the expected type (the type inferred from the parent property or specified by the external caller). The second parameter is the type name from the payload. The function should return the resolved type, or null if no such type was found.

See Also

ODataMessageReaderSettings Class
Microsoft.OData.Core Namespace

Return to top