26 lines
603 B
C++
26 lines
603 B
C++
#pragma once
|
|
|
|
namespace CVrCodeFormatUtils
|
|
{
|
|
//GB2312到UTF-8的转换
|
|
int GB2312ToUtf8(const char* gb2312, char* utf8);
|
|
|
|
//判断是否是utf8
|
|
bool IsTextUTF8(const char* str, long length);
|
|
|
|
//UTF-8到GB2312的转换
|
|
int Utf8ToGB2312(const char* utf8, char* gb2312);
|
|
|
|
//GB2312到Unicode的转换
|
|
int GB2312ToUnicode(const char* gb2312, char* unicode);
|
|
|
|
//Unicode到GB2312的转换
|
|
int UnicodeToGB2312(const char* unicode, int size, char*gb2312);
|
|
|
|
//UTF-8到Unicode的转换
|
|
int Utf8ToUnicode(const char* utf8, char*unicode);
|
|
|
|
//Unicode到UTF-8的转换
|
|
int UnicodeToUtf8(const char* unicode, int size, char* utf8);
|
|
}
|