PublicationOpener
class PublicationOpener(publicationParser: PublicationParser, contentProtections: List<ContentProtection> = emptyList(), onCreatePublication: Publication.Builder.() -> Unit = {})
Opens a Publication from an Asset.
Parameters
publicationParser
Parses the content of a publication Asset.
contentProtections
Opens DRM-protected publications.
onCreatePublication
Called on every parsed Publication.Builder. It can be used to modify the manifest, the root container or the list of service factories of a Publication.
Constructors
Link copied to clipboard
constructor(publicationParser: PublicationParser, contentProtections: List<ContentProtection> = emptyList(), onCreatePublication: Publication.Builder.() -> Unit = {})
Functions
Link copied to clipboard
suspend fun open(asset: Asset, credentials: String? = null, allowUserInteraction: Boolean, onCreatePublication: Publication.Builder.() -> Unit = {}, warnings: WarningLogger? = null): Try<Publication, PublicationOpener.OpenError>
Opens a Publication from the given asset.