aboutsummaryrefslogtreecommitdiff
path: root/src/xmlfilewriter.cpp
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/xmlfilewriter.cpp22
1 files changed, 22 insertions, 0 deletions
diff --git a/src/xmlfilewriter.cpp b/src/xmlfilewriter.cpp
new file mode 100644
index 0000000..b62fb11
--- /dev/null
+++ b/src/xmlfilewriter.cpp
@@ -0,0 +1,22 @@
1#include <stdio.h>
2#include <stdlib.h>
3#include "xmlfilewriter.h"
4
5XmlFileWriter::XmlFileWriter( const char *sFileName, const char *sIndent, XmlNode *pRoot ) :
6 XmlWriter( sIndent, pRoot )
7{
8 this->sFileName = sFileName;
9 fh = fopen( sFileName, "wt");
10 fprintf( fh, "<?xml version=\"1.0\"?>\n");
11}
12
13XmlFileWriter::~XmlFileWriter()
14{
15 fclose( fh );
16}
17
18void XmlFileWriter::writeString( const char *sString )
19{
20 fprintf( fh, sString );
21}
22