1#ifndef TAG_PARSER_MATROSKATAG_H
2#define TAG_PARSER_MATROSKATAG_H
32 void make(std::ostream &stream)
const;
34 std::uint64_t requiredSize()
const;
40 std::uint64_t m_targetsSize;
41 std::uint64_t m_simpleTagsSize;
42 std::vector<MatroskaTagFieldMaker> m_maker;
43 std::uint64_t m_tagSize;
44 std::uint64_t m_totalSize;
69 using Compare = std::less<typename FieldType::IdentifierType>;
78 static constexpr TagType tagType = TagType::MatroskaTag;
79 static constexpr std::string_view tagName =
"Matroska tag";
82 bool supportsTarget()
const override;
83 bool supportsMultipleValues(
KnownField field)
const override;
92 IdentifierType internallyGetFieldId(
KnownField field)
const;
93 KnownField internallyGetKnownField(
const IdentifierType &
id)
const;
The Diagnostics class is a container for DiagMessage.
The EbmlElement class helps to parse EBML files such as Matroska files.
std::less< typename FieldType::IdentifierType > Compare
Defines traits for the specified ImplementationType.
The FieldMapBasedTag provides a generic implementation of Tag which stores the tag fields using std::...
The MatroskaTagField class is used by MatroskaTag to store the fields.
The MatroskaTagMaker class helps writing Matroska "Tag"-elements storing tag information.
std::uint64_t requiredSize() const
Returns the number of bytes which will be written when making the tag.
const MatroskaTag & tag() const
Returns the associated tag.
void make(std::ostream &stream) const
Saves the tag (specified when constructing the object) to the specified stream (makes a "Tag"-element...
Implementation of TagParser::Tag for the Matroska container.
bool supportsTarget() const override
Returns an indication whether a target is supported by the tag.
bool supportsMultipleValues(KnownField field) const override
Allows multiple values for all fields.
MatroskaTagMaker prepareMaking(Diagnostics &diag)
Prepares making.
bool canEncodingBeUsed(TagTextEncoding encoding) const override
Returns an indication whether the specified encoding can be used to provide string values for the tag...
TagTargetLevel targetLevel() const override
Returns the name of the current tag target level.
void make(std::ostream &stream, Diagnostics &diag)
Writes tag information to the specified stream (makes a "Tag"-element).
MatroskaTag()
Constructs a new tag.
std::uint64_t level() const
Returns the level.
#define TAG_PARSER_EXPORT
Marks the symbol to be exported by the tagparser library.
Contains all classes and functions of the TagInfo library.
KnownField
Specifies the field.
TagTargetLevel
The TagTargetLevel enum specifies tag target levels.
TagTextEncoding
Specifies the text encoding.
MatroskaTagFlags
The MatroskaTagFlags enum specifies flags which controls parsing and making of Matroska tags.
constexpr TAG_PARSER_EXPORT TagTargetLevel matroskaTagTargetLevel(std::uint64_t targetLevelValue)
Returns the general TagTargetLevel for the Matroska specific targetLevelValue.
TagType
Specifies the tag type.
CPP_UTILITIES_MARK_FLAG_ENUM_CLASS(TagParser, TagParser::TagCreationFlags)