【7.1.6】更新serviceException,异常可携带返回值

pull/24/MERGE
fengshuonan 2021-12-10 18:55:28 +08:00
parent c88c32f7e9
commit 1ad0efe435
1 changed files with 16 additions and 0 deletions

View File

@ -65,6 +65,11 @@ public class ServiceException extends RuntimeException {
*/
private String moduleName;
/**
*
*/
private Object data;
/**
*
*/
@ -97,4 +102,15 @@ public class ServiceException extends RuntimeException {
this.userTip = exception.getUserTip();
}
/**
*
*/
public ServiceException(String moduleName, String errorCode, String userTip, Object data) {
super(userTip);
this.errorCode = errorCode;
this.moduleName = moduleName;
this.userTip = userTip;
this.data = data;
}
}