Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Checking the audiobook conformance of a RWPM + getting the durations #26

Open
mickael-menu opened this issue Jan 5, 2022 · 3 comments
Labels
enhancement New feature or request

Comments

@mickael-menu
Copy link
Member

According to the Readium Audiobook Profile, a RWPM must contain the duration property in the Link objects to conform.

However, the mobile toolkits Publication.conformsTo() API is only checking the media type in the reading order, not the availability of duration, so it's not checking full conformance. The reason for this is that we don't have the info for Zipped Audiobooks.

As a workaround, we could add an Audio/MediaPublicationService which will compute the duration from:

  • the duration Link object properties for streamed manifests
  • the resource metadata for Readium Packages and ZAB

Then, the conformsTo() API could use this info to check that the duration is available for all the resources of the reading order.

@mickael-menu mickael-menu added the enhancement New feature or request label Jan 5, 2022
@qnga
Copy link

qnga commented Jan 5, 2022

In hindsight, I feel like the conformsTo method might have been a mistake. To really check conformance to a profile, we have Publication.metadata.conformsTo. The method (vs the property) has been designed to determine which navigator should be used to render the publication. I don't think that's the responsibility of the shared module. Each navigator should be able to claim which publication it supports, whatever profile it conforms to, if any.

@mickael-menu
Copy link
Member Author

Each navigator should be able to claim which publication it supports, whatever profile it conforms to, if any.

I like this idea, testing a queue of navigator implementations until one handles the publication. In which case, that's fine if we're stricter with the conformsTo() API.

@qnga
Copy link

qnga commented Jan 6, 2022

Makes sense to me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants