I have multiple documents to parse and I need access to all the document objects for the lifetime of the creating class. How do I create an array of xml_document pointers as a member variable?
I've tried creating a single member variable as follows:
private: rapidxml::xml_document<> *m_pDoc; // doesn't compile
error: name followed by "::" must be a class or namespace name
I'm sure this is because the template class isn't well defined but I'm not sure how to properly define the pointer.
That compiles fine for me. The error message implies you've forgotten this, maybe?
#include "rapidxml.hpp"