puzhibing
2023-08-01 98bc380ae322eaac2ee7e21d0c565e30eacce2b5
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
package com.stylefeng.guns.core.exception;
 
/**
 * Guns异常枚举
 *
 * @author fengshuonan
 * @Date 2017/12/28 下午10:33
 */
public enum GunsExceptionEnum implements ServiceExceptionEnum {
 
    /**
     * 其他
     */
    INVLIDE_DATE_STRING(400, "输入日期格式不对"),
 
    /**
     * 其他
     */
    WRITE_ERROR(500, "渲染界面错误"),
 
    /**
     * 文件上传
     */
    FILE_READING_ERROR(400, "FILE_READING_ERROR!"),
    FILE_NOT_FOUND(400, "FILE_NOT_FOUND!"),
 
    /**
     * 错误的请求
     */
    REQUEST_NULL(400, "请求有错误"),
    SERVER_ERROR(500, "服务器异常");
 
    GunsExceptionEnum(int code, String message) {
        this.code = code;
        this.message = message;
    }
 
    private Integer code;
 
    private String message;
 
    @Override
    public Integer getCode() {
        return code;
    }
 
    public void setCode(Integer code) {
        this.code = code;
    }
 
    @Override
    public String getMessage() {
        return message;
    }
 
    public void setMessage(String message) {
        this.message = message;
    }
}