Files
Geoffrey Sisco 689495543e More efficient chapter parser dispatch (#8416)
## Description

This PR reduces avoidable per-parser stream opens during chapter loading
by introducing parser dispatch based on bounded magic-byte detection
with hint-based fallback ordering.

The implementation evolved during review from the original MIME-first
dispatch approach into a parser-neutral, magic-byte-first detection flow
that preserves compatibility behavior for unknown streams while
eliminating unnecessary parser probing for confidently detected formats.

Addresses part 1 of issue #8352.

### Checklist

- [x] I have read the contribution guidelines:
https://github.com/AntennaPod/AntennaPod/blob/develop/CONTRIBUTING.md#submit-a-pull-request
- [x] I have performed a self-review of my code, going through my
changes line by line and carefully considering why this line change is
necessary
- [x] I have run the automated code checks using `./gradlew checkstyle
lint spotbugsPlayDebug spotbugsDebug`
- [x] My code follows the style guidelines of the AntennaPod project:
https://antennapod.org/contribute/develop/app/code-style
- [ ] I have mentioned the corresponding issue and the relevant keyword
(e.g., "Closes: #xy") in the description (see
https://docs.github.com/en/issues/tracking-your-work-with-issues/linking-a-pull-request-to-an-issue)
- [x] If it is a core feature, I have added automated tests

---------

Co-authored-by: ByteHamster <info@bytehamster.com>
2026-05-28 14:24:55 +02:00
..
2026-04-19 15:11:38 +02:00

:parser:media

This module provides the tag parser for media files. This includes id3 or ogg/vorbis. It uses a custom-built recursive parser directly looking at the byte representation of the media files. The parser is used for extracting chapters and extracting media metadata such as description for local files.