muzei-api / / MuzeiArtProvider / openFile


open fun openFile(artwork: Artwork): InputStream

Provide an InputStream to the binary data associated with artwork that has not yet been cached. The default implementation retrieves the image from the persistent URI and supports URI schemes in the following formats:

Throwing any exception other than an IOException will be considered a permanent error that will result in a call to onInvalidArtwork.


artwork - The Artwork to open


IOException - if an error occurs while opening the image. The request will be retried automatically.

A valid InputStream for the artwork's image