Class SoHttpResponseException
An exception that allows for a given HttpResponseMessage to be returned to the client. This type is used for program-flow to be able to respond with certain http status codes. See OnlineTelemetryProcessor where we make sure this type is never sent to Application Insights.
Implements
Inherited Members
Namespace: SuperOffice.Exceptions
Assembly: SoCore.dll
Syntax
public class SoHttpResponseException : Exception, ISerializable
Constructors
SoHttpResponseException(HttpResponseMessage)
Initializes a new instance of the HttpResponseException class.
Declaration
public SoHttpResponseException(HttpResponseMessage response)
Parameters
| Type | Name | Description |
|---|---|---|
| HttpResponseMessage | response | The response message. |
SoHttpResponseException(HttpStatusCode)
Initializes a new instance of the HttpResponseException class.
Declaration
public SoHttpResponseException(HttpStatusCode statusCode)
Parameters
| Type | Name | Description |
|---|---|---|
| HttpStatusCode | statusCode | The status code of the response. |
Properties
Response
Gets the HttpResponseMessage to return to the client.
Declaration
public HttpResponseMessage Response { get; }
Property Value
| Type | Description |
|---|---|
| HttpResponseMessage |