StackTrace
Creates a new StackTrace object, which is based at the execution location. This is useful for finding out who called a function. throwable = new Throwable();
throwable = new Throwable();
create a stackTrace object for the given Throwableparamt The Throwable that you are interested in. throwable = t;
throwable = t;
Used by the Reporter classreturnThe text of a stack trace.seeReporter ByteArrayOutputStream baos = new ByteArrayOutputStream(); PrintWriter pw = new PrintWriter(baos); // create the stack trace throwable.printStackTrace(pw); pw.flush(); return baos.toString();
ByteArrayOutputStream baos = new ByteArrayOutputStream(); PrintWriter pw = new PrintWriter(baos); // create the stack trace throwable.printStackTrace(pw); pw.flush(); return baos.toString();