1 67 package servlet; 68 69 public class ApplyXSLTException extends Exception { 70 71 75 private String myMessage = ""; 76 77 81 private int myHttpStatusCode = javax.servlet.http.HttpServletResponse.SC_INTERNAL_SERVER_ERROR; 82 83 87 private Exception myException = null; 88 89 92 public ApplyXSLTException() 93 { 94 super(); 95 } 96 97 101 public ApplyXSLTException(String s) 102 { 103 super(); 104 myMessage = s; 105 } 106 107 111 public ApplyXSLTException(int hsc) 112 { 113 super(); 114 myHttpStatusCode = hsc; 115 } 116 117 122 public ApplyXSLTException(String s, int hsc) 123 { 124 super(); 125 myHttpStatusCode = hsc; 126 } 127 128 132 public ApplyXSLTException(Exception e) 133 { 134 super(); 135 myMessage = e.getMessage(); 136 myException = e; 137 } 138 139 144 public ApplyXSLTException (String s, Exception e) 145 { 146 super(); 147 myMessage = s; 148 myException = e; 149 } 150 151 156 public ApplyXSLTException(Exception e, int hsc) 157 { 158 super(); 159 myMessage = e.getMessage(); 160 myException = e; 161 myHttpStatusCode = hsc; 162 } 163 164 170 public ApplyXSLTException(String s, Exception e, int hsc) 171 { 172 super(); 173 myMessage = s; 174 myException = e; 175 myHttpStatusCode = hsc; 176 } 177 178 182 public String getMessage() 183 { 184 return myMessage; 185 } 186 187 191 public void appendMessage(String s) 192 { 193 myMessage += s; 194 } 195 196 200 public Exception getException() 201 { 202 return myException; 203 } 204 205 209 public int getStatusCode() 210 { 211 return myHttpStatusCode; 212 } 213 } 214 215 | Popular Tags |