public enum StateCode extends Enum<StateCode>
| Enum Constant and Description |
|---|
Accepted
用于异步时响应,已经接受到请求,正在执行
|
BadRequest
当服务器返回此状态时,客户端应当检查所传参数正确性
|
Error
服务器发生了异常
|
Forbidden
操作权限不足,被服务器驳回
|
NeedTOTP
当服务器返回此状态时,客户端应要求用户输入TOTP码
|
NoContent
服务器成功处理,但未返回内容
|
OK
完成请求
|
Partial
当服务器返回此状态时,客户端应当重新拉取确认各项数据是否变化
|
Reset
当服务器返回此状态时,客户端应当重新拉取用户信息
|
Unauthorized
当服务器返回此状态时,客户端应要求用户登录
|
Unavailable
服务器维护
|
| Modifier and Type | Method and Description |
|---|---|
Integer |
getCode() |
String |
getDescribe() |
void |
setCode(Integer code) |
void |
setDescribe(String describe) |
static StateCode |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static StateCode[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final StateCode OK
public static final StateCode Accepted
public static final StateCode NoContent
public static final StateCode Reset
public static final StateCode Partial
public static final StateCode BadRequest
public static final StateCode Unauthorized
public static final StateCode NeedTOTP
public static final StateCode Forbidden
public static final StateCode Error
public static final StateCode Unavailable
public static StateCode[] values()
for (StateCode c : StateCode.values()) System.out.println(c);
public static StateCode valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant with the specified nameNullPointerException - if the argument is nullpublic Integer getCode()
public void setCode(Integer code)
public String getDescribe()
public void setDescribe(String describe)
Copyright © 2020. All rights reserved.