Text handling routines for ADCH++. More...
#include <Text.h>
Static Public Member Functions | |
static ADCHPP_DLL string | acpToUtf8 (const string &str) throw () |
static const string & | acpToUtf8 (const string &str, string &tmp) throw () |
static ADCHPP_DLL wstring | acpToWide (const string &str) throw () |
static const wstring & | acpToWide (const string &str, wstring &tmp) throw () |
static ADCHPP_DLL string | utf8ToAcp (const string &str) throw () |
static const string & | utf8ToAcp (const string &str, string &tmp) throw () |
static ADCHPP_DLL wstring | utf8ToWide (const string &str) throw () |
static const wstring & | utf8ToWide (const string &str, wstring &tmp) throw () |
static ADCHPP_DLL bool | validateUtf8 (const string &str) throw () |
static ADCHPP_DLL string | wideToAcp (const wstring &str) throw () |
static const string & | wideToAcp (const wstring &str, string &tmp) throw () |
static ADCHPP_DLL string | wideToUtf8 (const wstring &str) throw () |
static const string & | wideToUtf8 (const wstring &str, string &tmp) throw () |
Private Types | |
typedef std::string | string |
typedef std::wstring | wstring |
Static Private Member Functions | |
static int | utf8ToWc (const char *str, wchar_t &c) |
static void | wcToUtf8 (wchar_t c, string &str) |
Text handling routines for ADCH++.
ADCH++ internally uses UTF-8 for (almost) all string:s, hence all foreign text must be converted appropriately... acp - ANSI code page used by the system wide - wide unicode string utf8 - UTF-8 representation of the string string - UTF-8 string (most of the time) wstring - Wide string
Taken from DC++.
Definition at line 36 of file Text.h.
typedef std::string adchpp::Text::string [private] |
typedef std::wstring adchpp::Text::wstring [private] |
Definition at line 113 of file Text.cpp.
References adchpp::Util::emptyStringW.
Definition at line 211 of file Text.cpp.
Referenced by adchpp::PluginManager::loadPlugin().
int adchpp::Text::utf8ToWc | ( | const char * | str, | |
wchar_t & | c | |||
) | [static, private] |
bool adchpp::Text::validateUtf8 | ( | const string & | str | ) | throw () [static] |
Definition at line 199 of file Text.cpp.
Referenced by adchpp::AdcCommand::parse().
void adchpp::Text::wcToUtf8 | ( | wchar_t | c, | |
string & | str | |||
) | [static, private] |
Definition at line 168 of file Text.cpp.
References adchpp::Util::emptyString.