FileDocCategorySizeDatePackage
Utility.javaAPI DocJava SE 5 API3362Fri Aug 26 14:55:26 BST 2005com.sun.org.apache.bcel.internal.verifier.exc

Utility

public final class Utility extends Object
A utility class providing convenience methods concerning Throwable instances.
version
$Id: Utility.java,v 1.1.1.1 2001/10/29 20:00:34 jvanzyl Exp $
author
Enver Haase
see
java.lang.Throwable

Fields Summary
Constructors Summary
private Utility()
This class is not instantiable.

Methods Summary
public static java.lang.StringgetStackTrace(java.lang.Throwable t)
This method returns the stack trace of a Throwable instance as a String.

		StringWriter sw = new StringWriter();
		PrintWriter pw = new PrintWriter(sw);
		t.printStackTrace(pw);
		return sw.toString();