-
- All Implemented Interfaces:
-
org.readium.r2.streamer.parser.PublicationParser
public final class EpubParser implements PublicationParser
Parses a Publication from an EPUB publication.
-
-
Constructor Summary
Constructors Constructor Description EpubParser(EpubPositionsService.ReflowableStrategy reflowablePositionsStrategy)
-
Method Summary
Modifier and Type Method Description Try<Publication.Builder, PublicationParser.ParseError>parse(Asset asset, WarningLogger warnings)Constructs a Publication.Builder to build a Publication from a publication asset. final <R extends Any> RreadDecodeOrElse(Readable $self, Url url, Function1<ByteArray, Try<R, DecodeError>> decode, Function1<ReadError, R> recover)-
-
Constructor Detail
-
EpubParser
EpubParser(EpubPositionsService.ReflowableStrategy reflowablePositionsStrategy)
- Parameters:
reflowablePositionsStrategy- Strategy used to calculate the number of positions in a reflowable resource.
-
-
Method Detail
-
parse
Try<Publication.Builder, PublicationParser.ParseError> parse(Asset asset, WarningLogger warnings)
Constructs a Publication.Builder to build a Publication from a publication asset.
- Parameters:
asset- Publication asset.warnings- Used to report non-fatal parsing warnings, such as publication authoring mistakes.
-
-
-
-