你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

ServiceContractResolver 类

定义

表示 使用的System.Net.Http.Formatting.JsonMediaTypeFormatter默认值Newtonsoft.Json.Serialization.IContractResolver,但添加了支持 camel 大小写序列化。 它使用格式化程序选择 System.Net.Http.Formatting.IRequiredMemberSelector 所需成员并识别 SerializableAttribute 类型注释。

public class ServiceContractResolver : System.Net.Http.Formatting.JsonContractResolver
type ServiceContractResolver = class
    inherit JsonContractResolver
Public Class ServiceContractResolver
Inherits JsonContractResolver
继承
System.Net.Http.Formatting.JsonContractResolver
ServiceContractResolver
派生

构造函数

ServiceContractResolver(MediaTypeFormatter)

使用给定formatter的 初始化 的新实例ServiceContractResolver,以用于解析所需成员。

方法

ResolvePropertyName(String)

表示 使用的System.Net.Http.Formatting.JsonMediaTypeFormatter默认值Newtonsoft.Json.Serialization.IContractResolver,但添加了支持 camel 大小写序列化。 它使用格式化程序选择 System.Net.Http.Formatting.IRequiredMemberSelector 所需成员并识别 SerializableAttribute 类型注释。

适用于