]> source.dussan.org Git - poi.git/commitdiff
Update/fix JavaDoc and add "throws"
authorDominik Stadler <centic@apache.org>
Fri, 10 Mar 2023 08:08:16 +0000 (08:08 +0000)
committerDominik Stadler <centic@apache.org>
Fri, 10 Mar 2023 08:08:16 +0000 (08:08 +0000)
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1908240 13f79535-47bb-0310-9956-ffa450edef68

poi-scratchpad/src/main/java/org/apache/poi/hsmf/datatypes/StoragePropertiesChunk.java
poi/src/main/java/org/apache/poi/util/ExceptionUtil.java

index 0ba57106fe616b28bb74fbcaece71ca62de46355..d236002ad1b845f86f4c73b4108e31315a591ce8 100644 (file)
@@ -54,7 +54,7 @@ public class StoragePropertiesChunk extends PropertiesChunk {
      * Writes out pre-calculated header values which assume any variable length property `data`
      *  field to already have Size and Reserved
      * @param out output stream (calling code must close this stream)
-     * @throws IOException
+     * @throws IOException If writing to the stream fails
      */
     public void writePreCalculatedValue(OutputStream out) throws IOException {
         // 8 bytes of reserved zeros
index db44ce9587081a95ac5b4df3e9c1e2d1215953dd..5e41052ede790bc8949e4e66bd4b9c8af6f37502 100644 (file)
@@ -49,8 +49,11 @@ public class ExceptionUtil {
      * </p>
      *
      * @param throwable to check
+     * @throws Error the input throwable if it is an <code>Error</code>.
+     * @throws RuntimeException the input throwable if it is an <code>RuntimeException</code>
+     * 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;
         }