Close HTML tags in Javadoc and better parameter names.

This commit is contained in:
Gary Gregory 2021-10-11 15:12:17 -04:00
parent a3a0645874
commit 5911e928c4
1 changed files with 8 additions and 7 deletions

View File

@ -85,6 +85,7 @@ public class ExceptionUtils {
* <p>The method searches for methods with specific names that return a * <p>The method searches for methods with specific names that return a
* {@code Throwable} object. This will pick up most wrapping exceptions, * {@code Throwable} object. This will pick up most wrapping exceptions,
* including those from JDK 1.4. * including those from JDK 1.4.
* </p>
* *
* <p>The default list searched for are:</p> * <p>The default list searched for are:</p>
* <ul> * <ul>
@ -240,13 +241,13 @@ public class ExceptionUtils {
* {ClassNameWithoutPackage}: {ThrowableMessage} * {ClassNameWithoutPackage}: {ThrowableMessage}
* </p> * </p>
* *
* @param th the throwable to get a message for, null returns empty string * @param throwable the throwable to get a message for, null returns empty string
* @return the message, non-null * @return the message, non-null
* @since 2.2 * @since 2.2
*/ */
public static String getRootCauseMessage(final Throwable th) { public static String getRootCauseMessage(final Throwable throwable) {
Throwable root = getRootCause(th); Throwable root = getRootCause(throwable);
root = root == null ? th : root; root = root == null ? throwable : root;
return getMessage(root); return getMessage(root);
} }
@ -296,11 +297,11 @@ public class ExceptionUtils {
* message contains a line that starts with: * message contains a line that starts with:
* {@code &quot;&nbsp;&nbsp;&nbsp;at&quot;.}</p> * {@code &quot;&nbsp;&nbsp;&nbsp;at&quot;.}</p>
* *
* @param t is any throwable * @param throwable is any throwable
* @return List of stack frames * @return List of stack frames
*/ */
static List<String> getStackFrameList(final Throwable t) { static List<String> getStackFrameList(final Throwable throwable) {
final String stackTrace = getStackTrace(t); final String stackTrace = getStackTrace(throwable);
final String linebreak = System.lineSeparator(); final String linebreak = System.lineSeparator();
final StringTokenizer frames = new StringTokenizer(stackTrace, linebreak); final StringTokenizer frames = new StringTokenizer(stackTrace, linebreak);
final List<String> list = new ArrayList<>(); final List<String> list = new ArrayList<>();