|
|||||||||
| 前のクラス 次のクラス | フレームあり フレームなし | ||||||||
| 概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド | ||||||||
java.lang.Objectjp.go.nict.langrid.commons.lang.ExceptionUtil
public class ExceptionUtil
例外関連のユーティリティ。
| コンストラクタの概要 | |
|---|---|
ExceptionUtil()
|
|
| メソッドの概要 | |
|---|---|
static void |
appendMessage(Throwable e,
Appendable buff)
例外のメッセージをException.printStackTraceと同じ形式で追加する。 |
static void |
appendStackTrace(Throwable e,
Appendable buff,
int maxStackDepth,
int maxTotalStackDepth)
例外からスタックトレースの情報を取得してException.printStackTraceと同じ形式で文字列バッファに追加する。 |
static String |
getMessageWithStackTrace(Throwable e)
例外からクラス、メッセージとスタックトレースの情報を取得する。 |
static String |
getMessageWithStackTrace(Throwable e,
int maxStackDepth,
int maxTotalStackDepth)
例外からクラス、メッセージとスタックトレースの情報を取得する。 |
| クラス java.lang.Object から継承されたメソッド |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| コンストラクタの詳細 |
|---|
public ExceptionUtil()
| メソッドの詳細 |
|---|
public static String getMessageWithStackTrace(Throwable e)
e - 例外
public static String getMessageWithStackTrace(Throwable e,
int maxStackDepth,
int maxTotalStackDepth)
e - 例外maxStackDepth - 取得するスタックトレースの最大数maxTotalStackDepth - 原因となる例外がある場合のトータルのスタックの深さ
public static void appendMessage(Throwable e,
Appendable buff)
throws IOException
e - 例外buff - 追加するバッファ
IOException - 追加に失敗した
public static void appendStackTrace(Throwable e,
Appendable buff,
int maxStackDepth,
int maxTotalStackDepth)
throws IOException
e - 例外buff - 追加するバッファmaxStackDepth - 取得するスタックトレースの最大数maxTotalStackDepth - 原因となる例外がある場合のトータルのスタックの深さ
IOException - 追加に失敗した
|
|||||||||
| 前のクラス 次のクラス | フレームあり フレームなし | ||||||||
| 概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド | ||||||||