1 11 12 package org.jivesoftware.messenger; 13 14 import java.io.PrintStream ; 15 import java.io.PrintWriter ; 16 17 22 public class NoSuchRouteException extends Exception { 23 private Throwable nestedThrowable = null; 24 25 public NoSuchRouteException() { 26 super(); 27 } 28 29 public NoSuchRouteException(String msg) { 30 super(msg); 31 } 32 33 public NoSuchRouteException(Throwable nestedThrowable) { 34 this.nestedThrowable = nestedThrowable; 35 } 36 37 public NoSuchRouteException(String msg, Throwable nestedThrowable) { 38 super(msg); 39 this.nestedThrowable = nestedThrowable; 40 } 41 42 public void printStackTrace() { 43 super.printStackTrace(); 44 if (nestedThrowable != null) { 45 nestedThrowable.printStackTrace(); 46 } 47 } 48 49 public void printStackTrace(PrintStream ps) { 50 super.printStackTrace(ps); 51 if (nestedThrowable != null) { 52 nestedThrowable.printStackTrace(ps); 53 } 54 } 55 56 public void printStackTrace(PrintWriter pw) { 57 super.printStackTrace(pw); 58 if (nestedThrowable != null) { 59 nestedThrowable.printStackTrace(pw); 60 } 61 } 62 } 63 | Popular Tags |