From 053ae3618dc60d152846a9cec8ddf2c40842fe5f Mon Sep 17 00:00:00 2001 From: Andreas Beeker Date: Sun, 2 May 2021 22:03:02 +0000 Subject: [PATCH] #65085 - LineRect shall throw more specific exceptions git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1889428 13f79535-47bb-0310-9956-ffa450edef68 --- .../main/java/org/apache/poi/hslf/usermodel/HSLFTable.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/poi-scratchpad/src/main/java/org/apache/poi/hslf/usermodel/HSLFTable.java b/poi-scratchpad/src/main/java/org/apache/poi/hslf/usermodel/HSLFTable.java index 98eba71017..c95d241836 100644 --- a/poi-scratchpad/src/main/java/org/apache/poi/hslf/usermodel/HSLFTable.java +++ b/poi-scratchpad/src/main/java/org/apache/poi/hslf/usermodel/HSLFTable.java @@ -352,7 +352,7 @@ implements HSLFShapeContainer, TableShape { @Override public double getRowHeight(int row) { if (row < 0 || row >= cells.length) { - throw new IllegalArgumentException("Row index '"+row+"' is not within range [0-"+(cells.length-1)+"]"); + throw new IndexOutOfBoundsException("Row index '"+row+"' is not within range [0-"+(cells.length-1)+"]"); } return cells[row][0].getAnchor().getHeight(); @@ -361,7 +361,7 @@ implements HSLFShapeContainer, TableShape { @Override public void setRowHeight(int row, final double height) { if (row < 0 || row >= cells.length) { - throw new IllegalArgumentException("Row index '"+row+"' is not within range [0-"+(cells.length-1)+"]"); + throw new IndexOutOfBoundsException("Row index '"+row+"' is not within range [0-"+(cells.length-1)+"]"); } // update row height in the table properties -- 2.39.5