com.silentgo.core.exception.AppException Maven / Gradle / Ivy
package com.silentgo.core.exception;
import com.silentgo.servlet.http.HttpStatus;
/**
* Project : silentgo
* com.silentgo.core.exception
*
* @author teddyzhu
*
* Created by teddyzhu on 16/8/22.
*/
public class AppException extends RuntimeException {
public int code = 500;
public AppException(String message, int code) {
super(message);
}
public AppException(int code) {
super(HttpStatus.getMessage(code));
}
public AppException(String message) {
super(message);
}
public int getCode() {
return code;
}
public void setCode(int code) {
this.code = code;
}
}