mirror of
https://github.com/pocoproject/poco.git
synced 2025-10-15 07:14:46 +02:00
GH #290: Unicode support
This commit is contained in:
@@ -108,6 +108,23 @@ public:
|
||||
convert(f, l, t);
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
static T to(const char* pChar)
|
||||
{
|
||||
T utfStr;
|
||||
Poco::UnicodeConverter::convert(pChar, utfStr);
|
||||
return utfStr;
|
||||
}
|
||||
|
||||
|
||||
template <typename T>
|
||||
static T to(const std::string& str)
|
||||
{
|
||||
T utfStr;
|
||||
Poco::UnicodeConverter::convert(str, utfStr);
|
||||
return utfStr;
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
static std::size_t UTFStrlen(const T* ptr)
|
||||
/// Returns the length (in characters) of a zero-terminated UTF string.
|
||||
|
Reference in New Issue
Block a user