1 19 20 package com.sslexplorer.boot; 21 22 27 public class CodedException extends Exception { 28 private int code; 29 30 36 public CodedException(int code) { 37 super(); 38 init(code); 39 } 40 41 48 public CodedException(int code, String message, Throwable cause) { 49 super(message, cause); 50 init(code); 51 } 52 53 59 public CodedException(int code, String message) { 60 super(message); 61 init(code); 62 } 63 64 70 public CodedException(int code, Throwable cause) { 71 super(cause); 72 init(code); 73 } 74 75 80 public int getCode() { 81 return code; 82 } 83 84 89 public void setCode(int code) { 90 this.code = code; 91 } 92 93 void init(int code) { 94 this.code = code; 95 } 96 } 97 | Popular Tags |