Tag Parser 12.4.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
localeawarestring.h
Go to the documentation of this file.
1#ifndef TAG_PARSER_LOCALEAWARESTRING_H
2#define TAG_PARSER_LOCALEAWARESTRING_H
3
4#include "./localehelper.h"
5
6#include <string>
7#include <vector>
8
9namespace TagParser {
10
14class TAG_PARSER_EXPORT LocaleAwareString : public std::string {
15public:
16 explicit LocaleAwareString(const std::string &value = std::string());
17 explicit LocaleAwareString(std::string &&value);
19
20 const Locale &locale() const;
21 Locale &locale();
22
23private:
24 Locale m_locale;
25};
26
30inline LocaleAwareString::LocaleAwareString(const std::string &value)
31 : std::string(value)
32{
33}
34
38inline LocaleAwareString::LocaleAwareString(std::string &&value)
39 : std::string(value)
40{
41}
42
49
53inline const Locale &LocaleAwareString::locale() const
54{
55 return m_locale;
56}
57
62{
63 return m_locale;
64}
65
66} // namespace TagParser
67
68#endif // TAG_PARSER_LOCALEAWARESTRING_H
The LocaleAwareString class is a standard string with locale information (languages,...
const Locale & locale() const
Returns the associated locale.
LocaleAwareString(const std::string &value=std::string())
Constructs a new LocaleAwareString from the specified standard string.
~LocaleAwareString()
Destroys the instance.
#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
The Locale struct specifies a language and/or a country using one or more LocaleDetail objects.