Manifest

data class Manifest(val context: List<String> = emptyList(), val metadata: Metadata, val links: List<Link> = emptyList(), val readingOrder: List<Link> = emptyList(), val resources: List<Link> = emptyList(), val tableOfContents: List<Link> = emptyList(), val subcollections: Map<String, List<PublicationCollection>> = emptyMap()) : JSONable

Holds the metadata of a Readium publication, as described in the Readium Web Publication Manifest.

Constructors

Link copied to clipboard
constructor(context: List<String> = emptyList(), metadata: Metadata, links: List<Link> = emptyList(), readingOrder: List<Link> = emptyList(), resources: List<Link> = emptyList(), tableOfContents: List<Link> = emptyList(), subcollections: Map<String, List<PublicationCollection>> = emptyMap())

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Functions

Link copied to clipboard

Returns whether this manifest conforms to the given Readium Web Publication Profile.

Link copied to clipboard

Creates a copy of the receiver Manifest, applying the given transformer to each component.

Link copied to clipboard

Finds all Links having the given rel in the manifest's links.

Link copied to clipboard
fun linkWithHref(href: Url): Link?

Finds the first Link with the given HREF in the manifest's links.

Link copied to clipboard
fun linkWithRel(rel: String): Link?

Finds the first Link with the given relation in the manifest's links.

Link copied to clipboard

Creates a new Locator object from a Link to a resource of this manifest.

Link copied to clipboard

Returns a copy of the receiver after normalizing its HREFs to the given baseUrl.

Link copied to clipboard

Returns a copy of the receiver after normalizing its HREFs to the link with rel="self".

Link copied to clipboard
open override fun toJSON(): JSONObject

Serializes a Publication to its RWPM JSON representation.

Link copied to clipboard
open override fun toString(): String

Returns the RWPM JSON representation for this manifest, as a string.