Class HttpExceptionDescriptorResponseHandlerExtensions
- Assembly
- Cuemon.Extensions.AspNetCore.Mvc.Formatters.Xml.dll
Extension methods for the HttpExceptionDescriptorResponseHandler class.
public static class HttpExceptionDescriptorResponseHandlerExtensions
- Inheritance
-
ObjectHttpExceptionDescriptorResponseHandlerExtensions
Methods
AddXmlResponseHandler(ICollection<HttpExceptionDescriptorResponseHandler>, IOptions<XmlFormatterOptions>)
Adds an HttpExceptionDescriptorResponseHandler to the list of handlers
that uses XmlSerializer as engine of serialization.
[Obsolete("This method will be removed in near future; please use extension method AddXmlExceptionResponseFormatter when configuring your services.")]
public static ICollection<HttpExceptionDescriptorResponseHandler> AddXmlResponseHandler(this ICollection<HttpExceptionDescriptorResponseHandler> handlers, IOptions<XmlFormatterOptions> options)
Parameters
handlers
ICollection<HttpExceptionDescriptorResponseHandler>The sequence of HttpExceptionDescriptorResponseHandler to extend.
options
IOptions<XmlFormatterOptions>The XmlFormatterOptions which need to be configured.
Returns
- ICollection<HttpExceptionDescriptorResponseHandler>
A reference to
handlers
so that additional calls can be chained.
Exceptions
- System.ArgumentNullException
handlers
cannot be null.