public enum ApiErrorCode extends java.lang.Enum<ApiErrorCode> implements IErrorCode
限定符和类型 | 方法和说明 |
---|---|
static ApiErrorCode |
fromCode(long code) |
long |
getCode()
错误编码 -1、失败 0、成功
|
java.lang.String |
getMsg()
错误描述
|
java.lang.String |
toString() |
static ApiErrorCode |
valueOf(java.lang.String name)
返回带有指定名称的该类型的枚举常量。
|
static ApiErrorCode[] |
values()
按照声明该枚举类型的常量的顺序, 返回
包含这些常量的数组。
|
public static final ApiErrorCode FAILED
public static final ApiErrorCode SUCCESS
public static ApiErrorCode[] values()
for (ApiErrorCode c : ApiErrorCode.values()) System.out.println(c);
public static ApiErrorCode valueOf(java.lang.String name)
name
- 要返回的枚举常量的名称。java.lang.IllegalArgumentException
- 如果该枚举类型没有带有指定名称的常量java.lang.NullPointerException
- 如果参数为空值public static ApiErrorCode fromCode(long code)
public long getCode()
IErrorCode
getCode
在接口中 IErrorCode
public java.lang.String getMsg()
IErrorCode
getMsg
在接口中 IErrorCode
public java.lang.String toString()
toString
在类中 java.lang.Enum<ApiErrorCode>