getContentFileEntry method
ArchiveFile
getContentFileEntry()
Implementation
ArchiveFile getContentFileEntry() {
final contentFilePath = ZipPathUtils.combine(
epubBookRef.schema.contentDirectoryPath,
fileName,
);
final contentFileEntry = epubBookRef._epubArchive.files
.firstWhereOrNull((ArchiveFile x) => x.name == contentFilePath);
if (contentFileEntry == null) {
throw Exception(
'EPUB parsing error: file $contentFilePath not found in archive.');
}
return contentFileEntry;
}