public class StackTraceUtil extends Object
Constructor and Description |
---|
StackTraceUtil() |
Modifier and Type | Method and Description |
---|---|
static String |
getCallingClassName() |
static String |
getCallingMethodName() |
static StackTraceElement |
getCallingStackTraceElement(List<StackTraceElementFilter> inExclusions) |
static String |
getCurrentClassName() |
static int |
getCurrentLineNumber() |
static String |
getCurrentMethodName() |
static String |
getExceptionStackTrace(Throwable inException)
Returns a stack trace formatted similarly to the one produced by e.printStackTrace().
|
static Throwable |
getRootException(Throwable inException)
Returns the root exception from an exception.
|
public StackTraceUtil()
public static String getCurrentMethodName()
public static String getCallingMethodName()
public static String getCurrentClassName()
public static String getCallingClassName()
public static int getCurrentLineNumber()
public static StackTraceElement getCallingStackTraceElement(List<StackTraceElementFilter> inExclusions)
public static Throwable getRootException(Throwable inException)
inException
- the exception from which to find the root exceptionpublic static String getExceptionStackTrace(Throwable inException)
inException
- the exception from which to get the stack trace