Interface ExceptionUtils.CustomStackTrace

  • All Known Implementing Classes:
    SourcedInterruptedException
    Enclosing class:
    ExceptionUtils

    public static interface ExceptionUtils.CustomStackTrace
    Interface allowing Throwable specializations to provide their custom stack trace presentation.
    Since:
    2.3.2
    • Method Detail

      • printCauseStack

        void printCauseStack​(PrintStream s,
                             String causeStr,
                             int causeIdx,
                             int stackDepth)
        Prints this Throwable as a cause to the output PrintStream s, not iterating over all inner causes!
        Parameters:
        s - output stream
        causeStr - the cause title
        causeIdx - the cause index over all causes known by caller
        stackDepth - the maximum depth for stack entries, or -1 for all
        Since:
        2.3.2
      • printStackTrace

        void printStackTrace​(PrintStream s,
                             int causeDepth,
                             int stackDepth)
        Custom printStackTrace method, similar to Throwable#printStackTrace(PrintStream, int, int).
        Parameters:
        s - output stream
        causeDepth - the maximum depth for causes, or -1 for all
        stackDepth - the maximum depth for stack entries, or -1 for all