Skip to main content

BusyBarApiException

Namespace: Busy.Bar

Thrown when the BUSY Bar responds with a non-2xx HTTP status.

public sealed class BusyBarApiException : System.Exception, System.Runtime.Serialization.ISerializable

Inheritance Object → Exception → BusyBarApiException
Implements ISerializable
Attributes NullableContextAttribute, NullableAttribute

Properties​

StatusCode​

The response's HTTP status code.

public HttpStatusCode StatusCode { get; }

Property Value​

HttpStatusCode

ReasonPhrase​

The response's HTTP reason phrase, if any.

public string? ReasonPhrase { get; }

Property Value​

String

RawBody​

The raw response body text, regardless of whether it could be parsed as JSON.

public string RawBody { get; }

Property Value​

String

ErrorBody​

The response body parsed as a BusyBarErrorBody, or if it wasn't valid JSON in that shape.

public BusyBarErrorBody? ErrorBody { get; }

Property Value​

BusyBarErrorBody

TargetSite​

public MethodBase? TargetSite { get; }

Property Value​

MethodBase

Message​

public virtual string Message { get; }

Property Value​

String

Data​

public virtual IDictionary Data { get; }

Property Value​

IDictionary

InnerException​

public Exception? InnerException { get; }

Property Value​

Exception

public virtual string? HelpLink { get; set; }

Property Value​

String

Source​

public virtual string? Source { get; set; }

Property Value​

String

HResult​

public int HResult { get; set; }

Property Value​

Int32

StackTrace​

public virtual string? StackTrace { get; }

Property Value​

String

Events​

SerializeObjectState​

Caution​

BinaryFormatter serialization is obsolete and should not be used. See https://aka.ms/binaryformatter for more information.


protected event EventHandler<SafeSerializationEventArgs>? SerializeObjectState;