ResponseError class final
HTTP 响应错误
服务器返回非 2xx 状态码。
- Inheritance
-
- Object
- SmartError
- ResponseError
Constructors
-
ResponseError({required String message, required int statusCode, String? statusMessage, Map<
String, List< ? responseHeaders, dynamic responseData, RequestOptions? requestOptions, StackTrace? stackTrace, Object? originalError, DateTime? timestamp})String> >
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- message → String
-
用户友好的错误消息
finalinherited
- originalError → Object?
-
原始异常
finalinherited
- requestOptions → RequestOptions?
-
原始请求配置(可选,非 Dio 错误可能为空)
finalinherited
- responseData → dynamic
-
响应数据
final
-
responseHeaders
→ Map<
String, List< ?String> > -
响应头
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- stackTrace → StackTrace?
-
堆栈跟踪
finalinherited
- statusCode → int
-
HTTP 状态码
final
- statusMessage → String?
-
状态消息
final
- timestamp → DateTime
-
错误发生时间戳
finalinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited