Table of Contents

AddResponseHandler Method

Definition

AddResponseHandler(IDecorator<ICollection<HttpExceptionDescriptorResponseHandler>>, Action<HttpExceptionDescriptorResponseHandlerOptions>)

Adds an HttpExceptionDescriptorResponseHandler to the underlying list of HttpExceptionDescriptorResponseHandler from the specified the decorator.

public static ICollection<HttpExceptionDescriptorResponseHandler> AddResponseHandler(this IDecorator<ICollection<HttpExceptionDescriptorResponseHandler>> decorator, Action<HttpExceptionDescriptorResponseHandlerOptions> setup)

Parameters

decorator IDecorator<ICollection<HttpExceptionDescriptorResponseHandler>>

The IDecorator<T> to extend.

setup Action<HttpExceptionDescriptorResponseHandlerOptions>

The HttpExceptionDescriptorResponseHandlerOptions that needs to be configured.

Returns

ICollection<HttpExceptionDescriptorResponseHandler>

A reference to Inner of decorator so that additional calls can be chained.

Exceptions

ArgumentNullException

decorator cannot be null - or - Inner property of decorator cannot be null - or - setup cannot be null.

ArgumentException

setup failed to configure an instance of HttpExceptionDescriptorResponseHandlerOptions in a valid state.