]> source.dussan.org Git - poi.git/commit
Deleting a sheet did not delete table parts and relations. Deleting a table needs...
authorGreg Woolsey <gwoolsey@apache.org>
Fri, 28 Jul 2017 18:01:36 +0000 (18:01 +0000)
committerGreg Woolsey <gwoolsey@apache.org>
Fri, 28 Jul 2017 18:01:36 +0000 (18:01 +0000)
commit9a0d34dc43d87a13dbe29d5b414180bd56609901
treee3fcbdfa6ee3b9d67c8e3735f2bf31665e242a6a
parent36d940ce3906ca59af69b39b79d678f8fc701a77
Deleting a sheet did not delete table parts and relations.  Deleting a table needs to also delete any queryTable relations and parts.

Previous behavior didn't result in documents Excel complained about, but left dead entries in the ZIP structure, which made it bigger and bugged me.

This change does not attempt to delete query connection definitions, as those aren't referenced as relations, and don't have a usage counter to ensure we only delete them if there are no other references.  In my samples I had query tables on multiple sheets using the same connection definition, and wanted to delete only one sheet/table but leave others.

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1803317 13f79535-47bb-0310-9956-ffa450edef68
src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFSheet.java
src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFTable.java
src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFWorkbook.java