Package com.globalmentor.java
Class Throwables
java.lang.Object
com.globalmentor.java.Throwables
Utilities for working with throwbles and exceptions.
- Author:
- Garret Wilson
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic String
getStackTraceString
(Throwable throwable) Returns a string representing the stack trace of the given throwable.
-
Constructor Details
-
Throwables
public Throwables()
-
-
Method Details
-
getStackTraceString
Returns a string representing the stack trace of the given throwable. This implementation returns a string in the same format as produced byThrowable.printStackTrace(PrintWriter)
.- Parameters:
throwable
- The throwable for which a strack trace string should be produced.- Returns:
- A string representation of the throwable's stack trace.
- Throws:
NullPointerException
- if the given throwable isnull
.- See Also:
-