| .. | .. |
|---|
| 4 | 4 | |
|---|
| 5 | 5 | public class SeCurisServiceException extends CurisException { |
|---|
| 6 | 6 | |
|---|
| 7 | | - private int status = 0; |
|---|
| 7 | + private int errorCode = 0; |
|---|
| 8 | 8 | |
|---|
| 9 | | - public SeCurisServiceException(int status, String msg) { |
|---|
| 9 | + public SeCurisServiceException(int errorCode, String msg) { |
|---|
| 10 | 10 | super(msg); |
|---|
| 11 | | - this.status = status; |
|---|
| 11 | + this.errorCode = errorCode; |
|---|
| 12 | + } |
|---|
| 13 | + |
|---|
| 14 | + public SeCurisServiceException(String msg) { |
|---|
| 15 | + super(msg); |
|---|
| 16 | + this.errorCode = ErrorCodes.UNEXPECTED_ERROR; |
|---|
| 12 | 17 | } |
|---|
| 13 | 18 | |
|---|
| 14 | 19 | public int getStatus() { |
|---|
| 15 | | - return status; |
|---|
| 20 | + return errorCode; |
|---|
| 16 | 21 | } |
|---|
| 17 | 22 | |
|---|
| 18 | 23 | /** |
|---|
| .. | .. |
|---|
| 24 | 29 | public static int UNEXPECTED_ERROR = 1000; |
|---|
| 25 | 30 | public static int INVALID_CREDENTIALS = 1001; |
|---|
| 26 | 31 | public static int UNAUTHORIZED_ACCESS = 1002; |
|---|
| 27 | | - |
|---|
| 32 | + public static int NOT_FOUND = 1003; |
|---|
| 33 | + public static int INVALID_FORMAT = 1004; |
|---|
| 34 | + |
|---|
| 28 | 35 | public static int INVALID_LICENSE_REQUEST_DATA = 1100; |
|---|
| 29 | 36 | public static int LICENSE_NOT_READY_FOR_RENEW = 1101; |
|---|
| 37 | + |
|---|
| 38 | + public static int INVALID_REQUEST_DATA = 1201; |
|---|
| 39 | + public static int INVALID_REQUEST_DATA_FORMAT = 1202; |
|---|
| 30 | 40 | } |
|---|
| 31 | 41 | } |
|---|