程序包 dev.utils.common

类 ThrowableUtils

java.lang.Object
dev.utils.common.ThrowableUtils

public final class ThrowableUtils extends Object
detail: 异常处理工具类
作者:
Ttt
  • 方法详细资料

    • getThrowable

      public static String getThrowable(Throwable throwable)
      获取异常信息
      参数:
      throwable - 异常
      返回:
      异常信息字符串
    • getThrowable

      public static String getThrowable(Throwable throwable, String errorInfo)
      获取异常信息
      参数:
      throwable - 异常
      errorInfo - 获取失败返回字符串
      返回:
      异常信息字符串
    • getThrowableStackTrace

      public static String getThrowableStackTrace(Throwable throwable)
      获取异常栈信息
      参数:
      throwable - 异常
      返回:
      异常栈信息字符串
    • getThrowableStackTrace

      public static String getThrowableStackTrace(Throwable throwable, String errorInfo)
      获取异常栈信息
      参数:
      throwable - 异常
      errorInfo - 获取失败返回字符串
      返回:
      异常栈信息字符串