Class HttpError
Defines a serializable container for arbitrary error information.
public sealed class HttpError : Dictionary<string, object>, IDictionary<string, object>, ICollection<KeyValuePair<string, object>>, IDictionary, ICollection, IReadOnlyDictionary<string, object>, IReadOnlyCollection<KeyValuePair<string, object>>, IEnumerable<KeyValuePair<string, object>>, IEnumerable, ISerializable, IDeserializationCallback, IXmlSerializable
- Inheritance
-
HttpError
- Implements
-
IXmlSerializable
- Inherited Members
Constructors
HttpError()
Initializes a new instance of the HttpError class.
public HttpError()
HttpError(Exception, bool)
Initializes a new instance of the HttpError class for exception.
public HttpError(Exception exception, bool includeErrorDetail)
Parameters
exception
ExceptionThe exception to use for error information.
includeErrorDetail
booltrue to include the exception information in the error; false otherwise
HttpError(string)
Initializes a new instance of the HttpError class containing error message message.
public HttpError(string message)
Parameters
message
stringThe error message to associate with this instance.
HttpError(ModelStateDictionary, bool)
Initializes a new instance of the HttpError class for modelState.
public HttpError(ModelStateDictionary modelState, bool includeErrorDetail)
Parameters
modelState
ModelStateDictionaryThe invalid model state to use for error information.
includeErrorDetail
booltrue to include exception messages in the error; false otherwise
Properties
Message
The error message associated with this instance.
public string Message { get; set; }