XmlSerializerInputFormatter 类   
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
此类使用 将输入 XML 数据反序列化为强类型对象 XmlSerializer
public ref class XmlSerializerInputFormatter : Microsoft::AspNetCore::Mvc::Formatters::TextInputFormatterpublic ref class XmlSerializerInputFormatter : Microsoft::AspNetCore::Mvc::Formatters::TextInputFormatter, Microsoft::AspNetCore::Mvc::Formatters::IInputFormatterExceptionPolicypublic class XmlSerializerInputFormatter : Microsoft.AspNetCore.Mvc.Formatters.TextInputFormatterpublic class XmlSerializerInputFormatter : Microsoft.AspNetCore.Mvc.Formatters.TextInputFormatter, Microsoft.AspNetCore.Mvc.Formatters.IInputFormatterExceptionPolicytype XmlSerializerInputFormatter = class
    inherit TextInputFormattertype XmlSerializerInputFormatter = class
    inherit TextInputFormatter
    interface IInputFormatterExceptionPolicyPublic Class XmlSerializerInputFormatter
Inherits TextInputFormatterPublic Class XmlSerializerInputFormatter
Inherits TextInputFormatter
Implements IInputFormatterExceptionPolicy- 继承
- 实现
构造函数
| XmlSerializerInputFormatter() | 
				已过时.
			 初始化 XmlSerializerInputFormatter 的新实例。 | 
| XmlSerializerInputFormatter(Boolean) | 
				已过时.
			 初始化 XmlSerializerInputFormatter 的新实例。 | 
| XmlSerializerInputFormatter(MvcOptions) | 初始化 XmlSerializerInputFormatter 的新实例。 | 
属性
| ExceptionPolicy | 获取标志,以指示正文模型绑定器是否应处理所有异常。 如果处理异常,则正文模型绑定器会将异常转换为模型状态错误,否则允许该异常传播。 | 
| MaxDepth | 指示可接受的输入 XML 深度。 | 
| SupportedEncodings | 获取此 TextInputFormatter支持的字符编码的可变集合。 读取数据时使用编码。(继承自 TextInputFormatter) | 
| SupportedMediaTypes | 获取此 InputFormatter支持的媒体类型元素的可变集合。(继承自 InputFormatter) | 
| WrapperProviderFactories | 获取 的列表 IWrapperProviderFactory ,以提供用于反序列化的包装类型。 | 
| XmlDictionaryReaderQuotas | 配额包括 - DefaultMaxDepth、DefaultMaxStringContentLength、DefaultMaxArrayLength、DefaultMaxBytesPerRead、DefaultMaxNameTableCharCount | 
方法
| CanRead(InputFormatterContext) | 确定这IInputFormatter是否可以反序列化 的 ModelType对象 | 
| CanReadType(Type) | 确定这 InputFormatter 是否可以反序列化给定  | 
| CreateSerializer(Type) | 在反序列化期间调用 以获取 XmlSerializer。 | 
| CreateXmlReader(Stream, Encoding, Type) | 在反序列化期间调用 以获取 XmlReader。 | 
| CreateXmlReader(Stream, Encoding) | 在反序列化期间调用 以获取 XmlReader。 | 
| GetCachedSerializer(Type) | 获取缓存的序列化程序,或创建并缓存给定类型的序列化程序。 | 
| GetDefaultValueForType(Type) | 获取给定类型的默认值。 用于在正文不包含任何内容时返回默认值。(继承自 InputFormatter) | 
| GetSerializableType(Type) | 获取 XML 将反序列化到的类型。 | 
| GetSupportedContentTypes(String, Type) | 获取 和  | 
| ReadAsync(InputFormatterContext) | 从请求正文中读取对象。(继承自 InputFormatter) | 
| ReadRequestBodyAsync(InputFormatterContext, Encoding) | 从请求正文中读取对象。 | 
| ReadRequestBodyAsync(InputFormatterContext) | 从请求正文中读取对象。(继承自 TextInputFormatter) | 
| SelectCharacterEncoding(InputFormatterContext) | 返回 Encoding 基于  |