2022-05-03 10:25:52 +00:00
|
|
|
|
#ifndef __HGSTRING_H__
|
|
|
|
|
#define __HGSTRING_H__
|
|
|
|
|
|
|
|
|
|
#include <string>
|
|
|
|
|
|
|
|
|
|
// 标准字符串:windows下为ansi编码,linux下为utf8编码
|
|
|
|
|
|
|
|
|
|
// UTF8转标准字符串
|
2022-05-23 10:29:23 +00:00
|
|
|
|
std::string Utf8ToStdString(const std::string& utf8Str);
|
2022-05-03 10:25:52 +00:00
|
|
|
|
|
|
|
|
|
// 标准字符串转UTF8
|
2022-05-23 10:29:23 +00:00
|
|
|
|
std::string StdStringToUtf8(const std::string& stdStr);
|
2022-05-03 10:25:52 +00:00
|
|
|
|
|
|
|
|
|
#endif /* __HGSTRING_H__ */
|