]> source.dussan.org Git - poi.git/commitdiff
XSSFReader extensibility
authorPJ Fanning <fanningpj@apache.org>
Sat, 23 Oct 2021 14:23:19 +0000 (14:23 +0000)
committerPJ Fanning <fanningpj@apache.org>
Sat, 23 Oct 2021 14:23:19 +0000 (14:23 +0000)
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1894513 13f79535-47bb-0310-9956-ffa450edef68

poi-ooxml/src/main/java/org/apache/poi/xssf/eventusermodel/XSSFBReader.java
poi-ooxml/src/main/java/org/apache/poi/xssf/eventusermodel/XSSFReader.java

index e26bfdeb0e359603a1e58624c8d6647d4fbb0ff1..883fce2c9b7103b91370e657c28000ef1f04f9ca 100644 (file)
@@ -127,12 +127,12 @@ public class XSSFBReader extends XSSFReader {
         }
 
         @Override
-        Set<String> getSheetRelationships() {
+        protected Set<String> getSheetRelationships() {
             return WORKSHEET_RELS;
         }
 
         @Override
-        Iterator<XSSFSheetRef> createSheetIteratorFromWB(PackagePart wb) throws IOException {
+        protected Iterator<XSSFSheetRef> createSheetIteratorFromWB(PackagePart wb) throws IOException {
             SheetRefLoader sheetRefLoader = new SheetRefLoader(wb.getInputStream());
             sheetRefLoader.parse();
             return sheetRefLoader.getSheets().iterator();
index 47eeecf396f410b05579fa973d601e9e0dfe9c84..bb795333ed95894310b3baecc116d7ea50595186 100644 (file)
@@ -215,26 +215,26 @@ public class XSSFReader {
         /**
          * Maps relId and the corresponding PackagePart
          */
-        private final Map<String, PackagePart> sheetMap;
+        protected final Map<String, PackagePart> sheetMap;
 
         /**
          * Current sheet reference
          */
-        XSSFSheetRef xssfSheetRef;
+        protected XSSFSheetRef xssfSheetRef;
 
         /**
          * Iterator over CTSheet objects, returns sheets in {@code logical} order.
          * We can't rely on the Ooxml4J's relationship iterator because it returns objects in physical order,
          * i.e. as they are stored in the underlying package
          */
-        final Iterator<XSSFSheetRef> sheetIterator;
+        protected final Iterator<XSSFSheetRef> sheetIterator;
 
         /**
          * Construct a new SheetIterator
          *
          * @param wb package part holding workbook.xml
          */
-        SheetIterator(PackagePart wb) throws IOException {
+        protected SheetIterator(PackagePart wb) throws IOException {
 
             /*
              * The order of sheets is defined by the order of CTSheet elements in workbook.xml
@@ -259,7 +259,7 @@ public class XSSFReader {
             }
         }
 
-        Iterator<XSSFSheetRef> createSheetIteratorFromWB(PackagePart wb) throws IOException {
+        protected Iterator<XSSFSheetRef> createSheetIteratorFromWB(PackagePart wb) throws IOException {
 
             XMLSheetRefReader xmlSheetRefReader = new XMLSheetRefReader();
             XMLReader xmlReader;
@@ -294,7 +294,7 @@ public class XSSFReader {
          *
          * @return all relationships that are sheet-like
          */
-        Set<String> getSheetRelationships() {
+        protected Set<String> getSheetRelationships() {
             return WORKSHEET_RELS;
         }