diff options
| author | Carl Hetherington <cth@carlh.net> | 2020-09-27 19:32:15 +0200 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2020-09-27 19:33:09 +0200 |
| commit | 627dfd9a5cdcce9e4122ef3041a38c3da2d3a120 (patch) | |
| tree | a250e81f9d6b746bfbadb2428dbdea8c1ac1de6d /src/language_tag.h | |
| parent | f3e69079eefa18407b110ff23df26f7711ebf7e5 (diff) | |
Load language tags from on-disk files rather than embedding them
into a .cc.
The .cc method causes compile times (and memory requirements) increase
enormously with some compilers.
Diffstat (limited to 'src/language_tag.h')
| -rw-r--r-- | src/language_tag.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/language_tag.h b/src/language_tag.h index d4d41fd7..abccdb2d 100644 --- a/src/language_tag.h +++ b/src/language_tag.h @@ -35,6 +35,7 @@ #define LIBDCP_LANGUAGE_TAG_H +#include <boost/filesystem.hpp> #include <boost/optional.hpp> #include <string> #include <vector> @@ -206,7 +207,7 @@ public: std::vector<std::pair<SubtagType, SubtagData> > subtags () const; - static std::vector<SubtagData> get_all (SubtagType type); + static std::vector<SubtagData> const& get_all (SubtagType type); static std::string subtag_type_name (SubtagType type); static boost::optional<std::string> get_subtag_description (SubtagType, std::string subtag); @@ -234,6 +235,9 @@ private: extern bool operator==(dcp::LanguageTag const& a, dcp::LanguageTag const& b); extern std::ostream& operator<<(std::ostream& os, dcp::LanguageTag const& tag); + +extern void load_language_tag_lists (boost::filesystem::path tags_directory); + } #endif |
