From 5b84aae94cd8f95ad2e7ab7c940dbba1ccb440bb Mon Sep 17 00:00:00 2001 From: Dominik Stadler Date: Fri, 10 Mar 2023 08:08:16 +0000 Subject: Update/fix JavaDoc and add "throws" git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1908240 13f79535-47bb-0310-9956-ffa450edef68 --- poi/src/main/java/org/apache/poi/util/ExceptionUtil.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'poi') diff --git a/poi/src/main/java/org/apache/poi/util/ExceptionUtil.java b/poi/src/main/java/org/apache/poi/util/ExceptionUtil.java index db44ce9587..5e41052ede 100644 --- a/poi/src/main/java/org/apache/poi/util/ExceptionUtil.java +++ b/poi/src/main/java/org/apache/poi/util/ExceptionUtil.java @@ -49,8 +49,11 @@ public class ExceptionUtil { *

* * @param throwable to check + * @throws Error the input throwable if it is an Error. + * @throws RuntimeException the input throwable if it is an RuntimeException + * Otherwise wraps the throwable in a RuntimeException. */ - public static void rethrow(Throwable throwable) { + public static void rethrow(Throwable throwable) throws Error, RuntimeException { if (throwable instanceof Error) { throw (Error) throwable; } -- cgit v1.2.3