com.groupdocs.parser

Interfaces

Classes

Exceptions

com.groupdocs.parser

Class EpubTextExtractorBase

    • Constructor Detail

      • EpubTextExtractorBase

        protected EpubTextExtractorBase(InputStream stream)

        Initializes a new instance of the EpubTextExtractorBase class.

        Parameters:
        stream - The stream of the document.
    • Method Detail

      • getCount

        public int getCount()

        Gets a total number of packages.

        Returns:
        A total number of packages.
      • get_Item

        public EpubPackage get_Item(int index)

        Gets a package.

        Parameters:
        index - An index of the package.
        Returns:
        An instance of EpubPackage class.
      • reset

        public void reset()

        Resets the current document.


        Resets the cursor's position. ExtractLine method will return the first line of the document.

        Overrides:
        reset in class TextExtractor
      • openContainerItem

        protected InputStream openContainerItem(String path)

        Creates a stream with the content of the document's item.

        Parameters:
        path - A path to the document's item.
        Returns:
        An instance of the java.io.InputStream with the content of the document's item or null if entity is not found.
      • extractItem

        protected abstract String extractItem(String path)

        Extracts a text from the document's item.

        Parameters:
        path - A path to the document's item.
        Returns:
        A string that contains all characters from the document's item.
      • prepareLine

        protected String prepareLine()

        Returns a line of the text.

        Specified by:
        prepareLine in class TextExtractor
        Returns:
        A string that represents a line of the text, or null if all characters have been read.