ProblemDetailsServiceCollectionExtensions.AddProblemDetails Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
AddProblemDetails(IServiceCollection) |
Adds services required for creation of ProblemDetails for failed requests. |
AddProblemDetails(IServiceCollection, Action<ProblemDetailsOptions>) |
Adds services required for creation of ProblemDetails for failed requests. |
AddProblemDetails(IServiceCollection)
Adds services required for creation of ProblemDetails for failed requests.
public static Microsoft.Extensions.DependencyInjection.IServiceCollection AddProblemDetails (this Microsoft.Extensions.DependencyInjection.IServiceCollection services);
static member AddProblemDetails : Microsoft.Extensions.DependencyInjection.IServiceCollection -> Microsoft.Extensions.DependencyInjection.IServiceCollection
<Extension()>
Public Function AddProblemDetails (services As IServiceCollection) As IServiceCollection
Parameters
- services
- IServiceCollection
The IServiceCollection to add the services to.
Returns
The IServiceCollection so that additional calls can be chained.
Applies to
AddProblemDetails(IServiceCollection, Action<ProblemDetailsOptions>)
Adds services required for creation of ProblemDetails for failed requests.
public static Microsoft.Extensions.DependencyInjection.IServiceCollection AddProblemDetails (this Microsoft.Extensions.DependencyInjection.IServiceCollection services, Action<Microsoft.AspNetCore.Http.ProblemDetailsOptions>? configure);
static member AddProblemDetails : Microsoft.Extensions.DependencyInjection.IServiceCollection * Action<Microsoft.AspNetCore.Http.ProblemDetailsOptions> -> Microsoft.Extensions.DependencyInjection.IServiceCollection
<Extension()>
Public Function AddProblemDetails (services As IServiceCollection, configure As Action(Of ProblemDetailsOptions)) As IServiceCollection
Parameters
- services
- IServiceCollection
The IServiceCollection to add the services to.
- configure
- Action<ProblemDetailsOptions>
The ProblemDetailsOptions to configure the services with.
Returns
The IServiceCollection so that additional calls can be chained.