Newer
Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#pragma once
#include "Visitor.h"
#include <string>
#include <memory>
// Forward declarations
namespace xmlpp {
class Document;
class Element;
}
namespace ChimeraTK {
// Forward declarations
class Application;
class VariableNetworkNode;
/**
* @brief The XMLGeneratorVisitor class
*
* This class is responsible for generating the XML representation of the Variables in an Application
*/
class XMLGeneratorVisitor : public Visitor<Application, VariableNetworkNode> {
public:
XMLGeneratorVisitor();
virtual ~XMLGeneratorVisitor() {}
void dispatch(const Application& app);
void dispatch(const VariableNetworkNode &node);
void save(const std::string &filename);
private:
std::shared_ptr<xmlpp::Document> _doc;
xmlpp::Element *_rootElement;
};
} // namespace ChimeraTK