1 2 24 25 26 27 28 package com.lutris.util; 29 30 36 public class FatalExceptionError extends Error { 37 40 Exception except; 41 42 47 public FatalExceptionError (Exception except) { 48 this.except = except; 49 } 50 51 56 public Exception getException () { 57 return except; 58 } 59 60 65 public String getMessage() { 66 return except.getMessage(); 67 } 68 69 74 public String getLocalizedMessage() { 75 return except.getLocalizedMessage(); 76 } 77 78 84 public String toString() { 85 String str = getClass().getName() + ": " + 86 except.getClass().getName(); 87 String message = except.getMessage(); 88 89 if (message == null) 90 return str; 91 return str + ": " + message; 92 } 93 94 98 public void printStackTrace() { 99 except.printStackTrace(); 100 } 101 102 106 public void printStackTrace(java.io.PrintStream str) { 107 except.printStackTrace(str); 108 } 109 110 114 public void printStackTrace(java.io.PrintWriter pw) { 115 except.printStackTrace(pw); 116 } 117 } 118 | Popular Tags |