acl/app/iconv/charset.h

32 lines
664 B
C
Raw Normal View History

#pragma once
2018-12-12 11:16:12 +08:00
class charset_radar
{
public:
charset_radar(void);
~charset_radar(void);
/**
*
* @param data
* @param len
* @param charset_result
* @return {bool}
2018-12-12 11:16:12 +08:00
*/
bool detact(const char *data, int len, acl::string &charset_result);
bool detact(const acl::string &data, acl::string &charset_result);
/*
*
2018-12-12 11:16:12 +08:00
*/
void setDebugMode(bool flag)
{
debug_mode_ = flag;
}
private:
bool debug_mode_;
};
//bool format_utf8(const char *str, int len, acl::string &out);