Early Preview
This is currently very much a preview. Please feel free to try things out,
but don't be upset if anything is not yet working. Feedback is welcome over on our
GitHub Dicussions page.
interface Microsoft.​AspNetCore.​Http.​IProblemDetailsService
Assembly: Microsoft.AspNetCore.Http.Abstractions
Defines a type that provide functionality to create a <see cref="T:Microsoft.AspNetCore.Mvc.ProblemDetails" /> response.
Methods
WriteAsync​(ProblemDetailsContext context)
Write a <see cref="T:Microsoft.AspNetCore.Mvc.ProblemDetails" /> response to the current context,
using the registered <see cref="T:Microsoft.AspNetCore.Http.IProblemDetailsWriter" /> services.
context
The <see cref="T:Microsoft.AspNetCore.Http.ProblemDetailsContext" /> associated with the current request/response.
Remarks
The <see cref="T:Microsoft.AspNetCore.Http.IProblemDetailsWriter" /> registered services
are processed in sequence and the processing is completed when:
<list type="bullet">
<item>
<description>One of them reports that the response was written successfully, or.</description>
</item>
<item>
<description>All <see cref="T:Microsoft.AspNetCore.Http.IProblemDetailsWriter" /> were executed and none of them was able to write the response successfully.</description>
</item>
</list>
System.​Threading.​Tasks.​ValueTask<​bool>
TryWriteAsync​(ProblemDetailsContext context)
Try to write a <see cref="T:Microsoft.AspNetCore.Mvc.ProblemDetails" /> response to the current context,
using the registered <see cref="T:Microsoft.AspNetCore.Http.IProblemDetailsWriter" /> services.
context
The <see cref="T:Microsoft.AspNetCore.Http.ProblemDetailsContext" /> associated with the current request/response.
Remarks
The <see cref="T:Microsoft.AspNetCore.Http.IProblemDetailsWriter" /> registered services
are processed in sequence and the processing is completed when:
<list type="bullet">
<item>
<description>One of them reports that the response was written successfully, or.</description>
</item>
<item>
<description>All <see cref="T:Microsoft.AspNetCore.Http.IProblemDetailsWriter" /> were executed and none of them was able to write the response successfully.</description>
</item>
</list>