mirror of
https://gitee.com/youlaitech/youlai-mall.git
synced 2024-12-22 04:47:11 +08:00
refactor: 自定义异常类名修改
This commit is contained in:
parent
c1a9c0c5cb
commit
41e89fb3d7
@ -10,24 +10,24 @@ import lombok.Getter;
|
||||
* @date 2022/7/31
|
||||
*/
|
||||
@Getter
|
||||
public class ApiException extends RuntimeException {
|
||||
public class BizException extends RuntimeException {
|
||||
|
||||
public IResultCode resultCode;
|
||||
|
||||
public ApiException(IResultCode errorCode) {
|
||||
public BizException(IResultCode errorCode) {
|
||||
super(errorCode.getMsg());
|
||||
this.resultCode = errorCode;
|
||||
}
|
||||
|
||||
public ApiException(String message){
|
||||
public BizException(String message){
|
||||
super(message);
|
||||
}
|
||||
|
||||
public ApiException(String message, Throwable cause){
|
||||
public BizException(String message, Throwable cause){
|
||||
super(message, cause);
|
||||
}
|
||||
|
||||
public ApiException(Throwable cause){
|
||||
public BizException(Throwable cause){
|
||||
super(cause);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user