CBlueUI
C++ 跨平台跨框架的数据可视化工具
|
xml文件储存类。xml文件中大量重复标签,采用共享字符串的方式,减少内存占用 更多...
Public 成员函数 | |
XmlStorageW (TransformTextProcW func=NULL) | |
XmlStorageW (const char *file_utf8, TransformTextProcW func=NULL) | |
XmlStorageW (const WCHAR *file, TransformTextProcW func=NULL) | |
~XmlStorageW () | |
void | Clear () |
清空并释放内存 | |
XMLItemW * | Root () |
跟节点 | |
int | LoadBuffer (const char *data, int len=-1, BOOL no_write=FALSE) |
加载xml格式数据 | |
int | LoadBufferJson (const char *jsonText, int len=-1, BOOL to_xml=FALSE) |
加载json数据并转换为xml树结构 | |
BeStringW | AddShareLabel (const char *str, int len, BOOL isKey=FALSE) |
BeStringW | FileBaseName () const |
静态 Public 成员函数 | |
static void | SaveAsXmlFile (const XMLItemW *root, const char *filepath) |
xml文件储存类。xml文件中大量重复标签,采用共享字符串的方式,减少内存占用
BUI::XmlStorageW::XmlStorageW | ( | TransformTextProcW | func = NULL | ) |
BUI::XmlStorageW::XmlStorageW | ( | const char * | file_utf8, |
TransformTextProcW | func = NULL |
||
) |
BUI::XmlStorageW::XmlStorageW | ( | const WCHAR * | file, |
TransformTextProcW | func = NULL |
||
) |
BUI::XmlStorageW::~XmlStorageW | ( | ) |
void BUI::XmlStorageW::Clear | ( | ) |
清空并释放内存
BeStringW BUI::XmlStorageW::FileBaseName | ( | ) | const |
加载xml格式数据
data | 数据 |
len | 数据长度 |
no_write | TRUE代表xmlText是不可写字符串,解析常量字符串时,需要标记为TRUE |
加载json数据并转换为xml树结构
jsonText | 数据 |
len | 数据长度 |
to_xml | TRUE表示将json格式转换为紧凑的XML格式。FALSE表示保持json的树结构 |
XMLItemW * BUI::XmlStorageW::Root | ( | ) |
跟节点
|
static |