ResponseException

class ResponseException(response: Response, message: String?, cause: Throwable?, tag: Any?) : HttpResponseException

状态码在200..299, 但是返回数据不符合业务要求可以抛出该异常

Parameters

response

响应信息

message

错误描述信息

cause

错误原因

tag

可携带任意对象, 一般用于在转换器/拦截器中添加然后传递给错误处理器去使用判断

Constructors

ResponseException
Link copied to clipboard
fun ResponseException(response: Response, message: String? = null, cause: Throwable? = null, tag: Any? = null)
响应信息

Properties

tag
Link copied to clipboard
var tag: Any? = null
可携带任意对象, 一般用于在转换器/拦截器中添加然后传递给错误处理器去使用判断