Best XML Library in C++, Fast Set-Up

2019-06-26 20:19发布

I was wondering what is the best XML Library in C++ (I'm using Visual Studio), considering fast set-up is critical. Basically, I want to create a file to save annotations on various .avi files.

Thank you in advance.

3条回答
老娘就宠你
2楼-- · 2019-06-26 20:40

I've used XercesC++ in the past and it was relatively painless to get working and working with.

I'm currently using MSXML and it is painful.

查看更多
Luminary・发光体
3楼-- · 2019-06-26 20:42

TinyXML is simple enough for almost all your use (if you don't bother having the whole xml representation in memory) but other libraries offer better important features :

  • RapidXML is made to be really really fast. It's used in the boost::property_tree library for the xml file read/write features. If you already use boost, using directly boost::property_tree might be a good idea, if adequate, as you already can easily use it with it's simple interface.
  • pugiXML has been mentionned as a good replacement for RapidXML by someone on the boost mailing list, but I'm not aware of the differences.
  • Xerces-C++ is made to allow you high level manipulations on xml like validation using xsd files -- but is really heavy on both speed and memory size...
  • wrappers around classic C xml libraries (like LibXML2) might be interesting choice if you don't find what you're looking for with the previous ones...
查看更多
男人必须洒脱
4楼-- · 2019-06-26 20:49

You should be able to get TinyXML set up and working in a matter of minutes.

查看更多
登录 后发表回答