Class ExceptionUtils


  • public class ExceptionUtils
    extends java.lang.Object
    • Constructor Summary

      Constructors 
      Constructor Description
      ExceptionUtils()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static java.lang.String getFullStackTrace​(java.lang.Throwable throwable)  
      static <T extends java.lang.Throwable>
      T
      getRootCause​(java.lang.Throwable t, java.lang.Class<T> type)
      Recursively attempts to cast the given Throwable and it's cause to an Throwable of the given type.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ExceptionUtils

        public ExceptionUtils()
    • Method Detail

      • getRootCause

        public static <T extends java.lang.Throwable> T getRootCause​(java.lang.Throwable t,
                                                                     java.lang.Class<T> type)
                                                              throws javax.servlet.ServletException
        Recursively attempts to cast the given Throwable and it's cause to an Throwable of the given type.
        Parameters:
        t -
        type -
        Returns:
        null of no suitable cause was found.
        Throws:
        javax.servlet.ServletException
      • getFullStackTrace

        public static java.lang.String getFullStackTrace​(java.lang.Throwable throwable)