首页>代码>基于SpringBoot+mybatis+Jsp的日记记录系统代码分享>/diary/src/main/java/com/rabbit/diary/bean/core/ExceptionCodeEnum.java
package com.rabbit.diary.bean.core;
/**
* 通用异常枚举
* @author Administrator
*
*/
public enum ExceptionCodeEnum {
SUCCESS("0000","返回成功!"),
ERROR("1111","与服务方通讯失败,请联系管理员!"),
NEED_LOGIN("9999", "用户未登录!"),
ERROR_PARAM("1000", "参数送错了!"),
EMPTY_PARAM("2000", "参数为空!"),
;
private String code;
private String desc;
private ExceptionCodeEnum(String code, String desc) {
this.code = code;
this.desc = desc;
}
public String getCode() {
return code;
}
public void setCode(String code) {
this.code = code;
}
public String getDesc() {
return desc;
}
//为了封装自定义信息,做特殊处理
public ExceptionCodeEnum setDesc(String desc) {
this.desc = desc;
return this;
}
}
最近下载更多
wbw123 LV6
11月30日
hanweinan6 LV13
2024年10月9日
wanglinddad LV55
2024年3月24日
zolscy LV24
2024年3月21日
rain112 LV31
2024年2月6日
全栈小陈 LV4
2024年1月21日
酷酷的轲 LV10
2023年6月29日
微信网友_6499449700175872 LV4
2023年5月31日
980363152 LV8
2023年5月15日
最代码官方 LV168
2023年5月14日
最近浏览更多
wbw123 LV6
11月30日
yuyuhshbbja
9月15日
暂无贡献等级
1140717565 LV2
7月18日
helloworldsbsb LV8
6月25日
潜心小白来到 LV3
6月10日
梁小贤 LV1
5月22日
PLVAE_514 LV2
3月10日
没有啊很开心啊 LV4
3月3日
denliv_hui LV14
2月28日
微信网友_7390007212789760
2月18日
暂无贡献等级

