libexpatpp
0.1.8
src
generator.hpp
Go to the documentation of this file.
1
6
#ifndef xmlpp_generator_hpp
7
#define xmlpp_generator_hpp
8
9
#include <string>
10
#include <list>
11
#include <memory>
12
#include <iostream>
13
14
namespace
xmlpp {
16
namespace
generator {
17
struct
attribute
{
18
std::string name;
//< name/ key of attribute
19
std::string value;
//< value of attribute
20
};
21
22
struct
node
{
23
virtual
void
serialize(std::ostream& os) = 0;
24
};
25
26
struct
element
:
public
node
{
27
std::list<attribute> attributes;
28
std::string name;
29
protected
:
30
void
serialize(std::ostream& os)
override
;
31
};
32
33
struct
composite_element
:
public
element
{
34
std::list<std::shared_ptr<node>> children;
35
protected
:
36
void
serialize(std::ostream& os)
override
;
37
};
38
39
struct
text
:
public
node
{
40
std::string value;
41
protected
:
42
void
serialize(std::ostream& os)
override
;
43
};
44
}
// end namespace generator
45
}
// end: namespace xmlpp
46
#endif
// #ifndef xmlpp_generator_hpp
xmlpp::generator::attribute
Definition
generator.hpp:17
xmlpp::generator::composite_element
Definition
generator.hpp:33
xmlpp::generator::element
Definition
generator.hpp:26
xmlpp::generator::node
Definition
generator.hpp:22
xmlpp::generator::text
Definition
generator.hpp:39
Generated by
1.9.8