1 #ifndef EXIV2_UTILS_HPP
2 #define EXIV2_UTILS_HPP
10 constexpr
bool startsWith(std::string_view s, T start) {
11 #ifdef __cpp_lib_starts_ends_with
12 return s.starts_with(start);
14 return s.find(start) == 0;
19 constexpr
bool contains(std::string_view s, T c) {
20 #ifdef __cpp_lib_string_contains
23 return s.find(c) != std::string_view::npos;
28 std::string
upper(
const std::string& str);
31 std::string
lower(
const std::string& a);
35 #endif // EXIV2_UTILS_HPP
Helper structure for the Matroska tags lookup table.
Definition: matroskavideo.hpp:39
std::string lower(const std::string &a)
Returns the lowercase version of str.
Definition: utils.cpp:14
std::string upper(const std::string &str)
Returns the uppercase version of str.
Definition: utils.cpp:8