Closed epubreader closed 7 years ago
Sure thing.
But just for the sake of curiosity, why do you need another constructor? Can't you just use the current one with file.getPath()? What would be the difference?
Also epub file is not used as java.io.File but java.util.zip.ZipFile. And java.util.zip.ZipFile is created in setFullContent method, from given path.
The only difference in the additional constructor would be epubFile.getAbsolutePath() instead of path parameter.
This still looks redundant to me since I didn't get any explanation.
You could just call file.getAbsolutePath and send the path.
please change the method setFullContent to support java.io.File, thanks.
Reader reader = new Reader(); reader.setMaxContentPerSection(1000); // Max string length for the current page. reader.setIsIncludingTextContent(true); // Optional, to return the tags-excluded version. reader.setFullContent(new File(epubFilePath)); // Must call before readSection.