Class ProblemDetailsCustomizer
- Namespace
- Arbiter.CommandQuery.Endpoints
- Assembly
- Arbiter.CommandQuery.Endpoints.dll
Service to customize the ProblemDetails response for exceptions.
public static class ProblemDetailsCustomizer
- Inheritance
-
ProblemDetailsCustomizer
- Inherited Members
Methods
Configure(ProblemDetailsOptions)
Configures the ProblemDetailsOptions for customizing the ProblemDetails response.
public static void Configure(ProblemDetailsOptions options)
Parameters
options
ProblemDetailsOptionsThe problem details options
CustomizeProblemDetails(ProblemDetailsContext)
Customizes the ProblemDetails response based on the exception type.
public static void CustomizeProblemDetails(ProblemDetailsContext context)
Parameters
context
ProblemDetailsContextThe problem details context
ToProblemDetails(Exception)
Converts an exception to a ProblemDetails object.
public static ProblemDetails ToProblemDetails(this Exception exception)
Parameters
exception
ExceptionThe exception to convert
Returns
- ProblemDetails
A ProblemDetails instance based on the exception