mirror of
https://github.com/ZLMediaKit/ZLMediaKit.git
synced 2026-06-14 12:05:58 +08:00
windows支持gb2312编码
This commit is contained in:
@@ -37,13 +37,18 @@ namespace Http {
|
||||
|
||||
class strCoding {
|
||||
public:
|
||||
static string UrlUTF8Encode(const char * str); //urlutf8 编码
|
||||
static string UrlUTF8Encode(const string &str); //urlutf8 编码
|
||||
static string UrlUTF8Decode(const string &str); //urlutf8解码
|
||||
|
||||
static string UrlGB2312Encode(const string &str); //urlgb2312编码
|
||||
static string UrlGB2312Decode(const string &str); //urlgb2312解码
|
||||
#if defined(_WIN32)
|
||||
static string UTF8ToGB2312(const string &str);//utf_8转为gb2312
|
||||
static string GB2312ToUTF8(const string &str); //gb2312 转utf_8
|
||||
#endif//defined(_WIN32)
|
||||
private:
|
||||
strCoding(void);
|
||||
virtual ~strCoding(void);
|
||||
static inline char CharToInt(char ch);
|
||||
static inline char StrToBin(const char *str);
|
||||
};
|
||||
|
||||
} /* namespace Http */
|
||||
|
||||
Reference in New Issue
Block a user