-
- All Implemented Interfaces:
-
android.os.Parcelable,org.readium.r2.shared.JSONable
public final class Metadata implements JSONable, Parcelable
https://readium.org/webpub-manifest/schema/metadata.schema.json
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public classMetadata.Companion
-
Field Summary
-
Constructor Summary
Constructors Constructor Description Metadata(String identifier, String type, Set<Publication.Profile> conformsTo, LocalizedString localizedTitle, LocalizedString localizedSubtitle, LocalizedString localizedSortAs, Date modified, Date published, Accessibility accessibility, List<String> languages, List<Subject> subjects, List<Contributor> authors, List<Contributor> translators, List<Contributor> editors, List<Contributor> artists, List<Contributor> illustrators, List<Contributor> letterers, List<Contributor> pencilers, List<Contributor> colorists, List<Contributor> inkers, List<Contributor> narrators, List<Contributor> contributors, List<Contributor> publishers, List<Contributor> imprints, ReadingProgression readingProgression, String description, Double duration, Integer numberOfPages, Map<String, List<Contributor>> belongsTo, List<Contributor> belongsToCollections, List<Contributor> belongsToSeries, Map<String, Object> otherMetadata)Metadata(String identifier, String type, Set<Publication.Profile> conformsTo, LocalizedString localizedTitle, LocalizedString localizedSubtitle, LocalizedString localizedSortAs, Date modified, Date published, Accessibility accessibility, List<String> languages, List<Subject> subjects, List<Contributor> authors, List<Contributor> translators, List<Contributor> editors, List<Contributor> artists, List<Contributor> illustrators, List<Contributor> letterers, List<Contributor> pencilers, List<Contributor> colorists, List<Contributor> inkers, List<Contributor> narrators, List<Contributor> contributors, List<Contributor> publishers, List<Contributor> imprints, ReadingProgression readingProgression, String description, Double duration, Integer numberOfPages, Map<String, List<Contributor>> belongsTo, Map<String, Object> otherMetadata)
-
Method Summary
-
-
Constructor Detail
-
Metadata
Metadata(String identifier, String type, Set<Publication.Profile> conformsTo, LocalizedString localizedTitle, LocalizedString localizedSubtitle, LocalizedString localizedSortAs, Date modified, Date published, Accessibility accessibility, List<String> languages, List<Subject> subjects, List<Contributor> authors, List<Contributor> translators, List<Contributor> editors, List<Contributor> artists, List<Contributor> illustrators, List<Contributor> letterers, List<Contributor> pencilers, List<Contributor> colorists, List<Contributor> inkers, List<Contributor> narrators, List<Contributor> contributors, List<Contributor> publishers, List<Contributor> imprints, ReadingProgression readingProgression, String description, Double duration, Integer numberOfPages, Map<String, List<Contributor>> belongsTo, List<Contributor> belongsToCollections, List<Contributor> belongsToSeries, Map<String, Object> otherMetadata)
-
Metadata
Metadata(String identifier, String type, Set<Publication.Profile> conformsTo, LocalizedString localizedTitle, LocalizedString localizedSubtitle, LocalizedString localizedSortAs, Date modified, Date published, Accessibility accessibility, List<String> languages, List<Subject> subjects, List<Contributor> authors, List<Contributor> translators, List<Contributor> editors, List<Contributor> artists, List<Contributor> illustrators, List<Contributor> letterers, List<Contributor> pencilers, List<Contributor> colorists, List<Contributor> inkers, List<Contributor> narrators, List<Contributor> contributors, List<Contributor> publishers, List<Contributor> imprints, ReadingProgression readingProgression, String description, Double duration, Integer numberOfPages, Map<String, List<Contributor>> belongsTo, Map<String, Object> otherMetadata)
- Parameters:
readingProgression- WARNING: This contains the reading progression as declared in the publication, so it might be AUTO.otherMetadata- Additional metadata for extensions, as a JSON dictionary.
-
-
Method Detail
-
getBelongsToCollections
final List<Contributor> getBelongsToCollections()
-
getBelongsToSeries
final List<Contributor> getBelongsToSeries()
-
getLanguage
final Language getLanguage()
Returns the Language resolved from the declared BCP 47 primary language.
-
getEffectiveReadingProgression
final ReadingProgression getEffectiveReadingProgression()
-
getRdfType
final String getRdfType()
-
getMultilanguageTitle
final LocalizedString getMultilanguageTitle()
-
getDirection
final String getDirection()
-
getPublicationDate
final String getPublicationDate()
-
getRendition
final Presentation getRendition()
-
getIdentifier
final String getIdentifier()
-
getConformsTo
final Set<Publication.Profile> getConformsTo()
-
getLocalizedTitle
final LocalizedString getLocalizedTitle()
-
getLocalizedSubtitle
final LocalizedString getLocalizedSubtitle()
-
getLocalizedSortAs
final LocalizedString getLocalizedSortAs()
-
getModified
final Date getModified()
-
getPublished
final Date getPublished()
-
getAccessibility
final Accessibility getAccessibility()
-
getLanguages
final List<String> getLanguages()
-
getSubjects
final List<Subject> getSubjects()
-
getAuthors
final List<Contributor> getAuthors()
-
getTranslators
final List<Contributor> getTranslators()
-
getEditors
final List<Contributor> getEditors()
-
getArtists
final List<Contributor> getArtists()
-
getIllustrators
final List<Contributor> getIllustrators()
-
getLetterers
final List<Contributor> getLetterers()
-
getPencilers
final List<Contributor> getPencilers()
-
getColorists
final List<Contributor> getColorists()
-
getInkers
final List<Contributor> getInkers()
-
getNarrators
final List<Contributor> getNarrators()
-
getContributors
final List<Contributor> getContributors()
-
getPublishers
final List<Contributor> getPublishers()
-
getImprints
final List<Contributor> getImprints()
-
getReadingProgression
final ReadingProgression getReadingProgression()
-
getDescription
final String getDescription()
-
getDuration
final Double getDuration()
-
getNumberOfPages
final Integer getNumberOfPages()
-
getBelongsTo
final Map<String, List<Contributor>> getBelongsTo()
-
getOtherMetadata
final Map<String, Object> getOtherMetadata()
-
toJSON
JSONObject toJSON()
Serializes a Metadata to its RWPM JSON representation.
-
get
final Object get(String key)
Syntactic sugar to access the otherMetadata values by subscripting Metadata directly.
metadata["layout"] == metadata.otherMetadata["layout"]
-
titleForLang
@Deprecated(message = "Use [localizedTitle.get] instead", replaceWith = @ReplaceWith(imports = {}, expression = "localizedTitle.translationForLanguage(key)?.string")) final String titleForLang(String key)
-
writeJSON
@Deprecated(message = "Renamed into [toJSON]", replaceWith = @ReplaceWith(imports = {}, expression = "toJSON()")) final JSONObject writeJSON()
-
-
-
-