Tag Parser 12.5.0
C++ library for reading and writing MP4 (iTunes), ID3, Vorbis, Opus, FLAC and Matroska tags
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
matroskachapter.h
Go to the documentation of this file.
1#ifndef TAG_PARSER_MATROSKACHAPTER_H
2#define TAG_PARSER_MATROSKACHAPTER_H
3
5
6#include <memory>
7
8namespace TagParser {
9
10class EbmlElement;
11
13public:
14 MatroskaChapter(EbmlElement *chapterAtomElement);
15 ~MatroskaChapter() override;
16
17 MatroskaChapter *nestedChapter(std::size_t index) override;
18 const MatroskaChapter *nestedChapter(std::size_t index) const override;
19 std::size_t nestedChapterCount() const override;
20 void clear() override;
21
22protected:
23 void internalParse(Diagnostics &diag, AbortableProgressFeedback &progress) override;
24
25private:
26 EbmlElement *m_chapterAtomElement;
27 std::vector<std::unique_ptr<MatroskaChapter>> m_nestedChapters;
28};
29
31{
32 return m_nestedChapters[index].get();
33}
34
35inline const MatroskaChapter *MatroskaChapter::nestedChapter(std::size_t index) const
36{
37 return m_nestedChapters[index].get();
38}
39
40inline std::size_t MatroskaChapter::nestedChapterCount() const
41{
42 return m_nestedChapters.size();
43}
44
45} // namespace TagParser
46
47#endif // TAG_PARSER_MATROSKACHAPTER_H
The AbortableProgressFeedback class provides feedback about an ongoing operation via callbacks.
AbstractChapter()
Constructs a new chapter.
The Diagnostics class is a container for DiagMessage.
The EbmlElement class helps to parse EBML files such as Matroska files.
Definition ebmlelement.h:32
MatroskaChapter(EbmlElement *chapterAtomElement)
Constructs a new MatroskaChapter for the specified chapterAtomElement.
void internalParse(Diagnostics &diag, AbortableProgressFeedback &progress) override
Parses the "ChapterAtom"-element which has been specified when constructing the object.
std::size_t nestedChapterCount() const override
Returns the number of nested chapters.
void clear() override
Resets the object to its initial state.
MatroskaChapter * nestedChapter(std::size_t index) override
Returns the nested chapter with the specified index.
#define TAG_PARSER_EXPORT
Marks the symbol to be exported by the tagparser library.
Definition global.h:14
Contains all classes and functions of the TagInfo library.
Definition aaccodebook.h:10