]> source.dussan.org Git - poi.git/commit
HSSFWorkbook.getSheet(): Return first found sheet
authorDominik Stadler <centic@apache.org>
Sun, 7 Jul 2024 05:03:15 +0000 (05:03 +0000)
committerDominik Stadler <centic@apache.org>
Sun, 7 Jul 2024 05:03:15 +0000 (05:03 +0000)
commit164c239a52ac44383c4cbad9cbf607a9e93b7f57
tree399c67b7cca9ced5e19ab0477525b48be8e57b5f
parentd090c6b77ab8162b6cd2fcd7f57b67e694a53c68
HSSFWorkbook.getSheet(): Return first found sheet

We do not need to loop over all sheets always but should
be able to return the first found sheet.

This may change semantics for cases where there are
multiple sheets where name only differs in case, but
the JavaDoc did not state which one will be returned.

All three implementations (HSSF, XSSF, SXSSF)
now behave the same way.

Closes #653

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1918982 13f79535-47bb-0310-9956-ffa450edef68
poi-ooxml/src/main/java/org/apache/poi/xssf/streaming/SXSSFWorkbook.java
poi-ooxml/src/main/java/org/apache/poi/xssf/usermodel/XSSFWorkbook.java
poi/src/main/java/org/apache/poi/hssf/usermodel/HSSFWorkbook.java