Class Exceptions

java.lang.Object
cn.xuanyuanli.core.util.Exceptions

public class Exceptions extends Object
异常工具
Author:
John Li
  • Constructor Details

    • Exceptions

      public Exceptions()
  • Method Details

    • throwException

      public static void throwException(Throwable e)
      抛出运行时异常
      Parameters:
      e - e
    • exceptionToString

      public static String exceptionToString(Exception exception)
      获得异常堆栈信息
      Parameters:
      exception - 异常
      Returns:
      String
    • exceptionToString

      public static String exceptionToString(Exception exception, int len)
      获得异常堆栈信息
      Parameters:
      exception - 异常
      len - len
      Returns:
      String