diff options
author | Dimitri van Heesch <dimitri@stack.nl> | 2003-07-08 20:06:16 (GMT) |
---|---|---|
committer | Dimitri van Heesch <dimitri@stack.nl> | 2003-07-08 20:06:16 (GMT) |
commit | 5444ff60bbf81c46841827e66e72f3148edde9ff (patch) | |
tree | 0ff0fae4a5be0021848d96eb18ee8505ff6b9b5d /src/xmlgen.cpp | |
parent | 17c14fb5230cfc532577c32df1d10223534392d8 (diff) | |
download | Doxygen-5444ff60bbf81c46841827e66e72f3148edde9ff.zip Doxygen-5444ff60bbf81c46841827e66e72f3148edde9ff.tar.gz Doxygen-5444ff60bbf81c46841827e66e72f3148edde9ff.tar.bz2 |
Release-1.3.2-20030708
Diffstat (limited to 'src/xmlgen.cpp')
-rw-r--r-- | src/xmlgen.cpp | 29 |
1 files changed, 27 insertions, 2 deletions
diff --git a/src/xmlgen.cpp b/src/xmlgen.cpp index 7cef7d7..2f58fd4 100644 --- a/src/xmlgen.cpp +++ b/src/xmlgen.cpp @@ -47,6 +47,14 @@ // debug inside output //#define XML_DB(x) QCString __t;__t.sprintf x;m_t << __t +//------------------ + +static const char index_xsd[] = +#include "index_xsd.h" +; + +//------------------ + inline void writeXMLString(QTextStream &t,const char *s) { @@ -1448,16 +1456,33 @@ void generateXML() } } QDir xmlDir(outputDirectory); - QCString fileName=outputDirectory+"/index.xml"; + QCString fileName=outputDirectory+"/index.xsd"; QFile f(fileName); if (!f.open(IO_WriteOnly)) { err("Cannot open file %s for writing!\n",fileName.data()); return; } + f.writeBlock(index_xsd,strlen(index_xsd)); + f.close(); + + fileName=outputDirectory+"/index.xml"; + f.setName(fileName); + if (!f.open(IO_WriteOnly)) + { + err("Cannot open file %s for writing!\n",fileName.data()); + return; + } QTextStream t(&f); t.setEncoding(QTextStream::Latin1); - writeXMLHeader(t); + + // write index header + t << "<?xml version='1.0' encoding='" << theTranslator->idLanguageCharset() + << "' standalone='no'?>" << endl;; + t << "<doxygen xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" "; + t << "xsi:noNamespaceSchemaLocation=\"index.xsd\" "; + t << "version=\"" << versionString << "\">" << endl; + ClassSDict::Iterator cli(Doxygen::classSDict); ClassDef *cd; for (cli.toFirst();(cd=cli.current());++cli) |