Class RequestExceptionHandlerState<TResponse>
Tracks whether an exception was handled and which response to return in its place.
public sealed class RequestExceptionHandlerState<TResponse>
Type Parameters
TResponseThe response type.
- Inheritance
-
RequestExceptionHandlerState<TResponse>
- Inherited Members
Constructors
RequestExceptionHandlerState()
public RequestExceptionHandlerState()
Properties
Handled
true once a handler called SetHandled(TResponse).
public bool Handled { get; }
Property Value
Response
The fallback response supplied via SetHandled(TResponse).
public TResponse? Response { get; }
Property Value
- TResponse
Methods
SetHandled(TResponse)
Marks the exception as handled and stores the response to return.
public void SetHandled(TResponse response)
Parameters
responseTResponseThe response to return instead of throwing.