LIMA
Libre Multilingual Analyzer — C++ API
Loading...
Searching...
No Matches
xmlConfigurationFileHandler.h
Go to the documentation of this file.
1// Copyright 2002-2013 CEA LIST
2// SPDX-FileCopyrightText: 2022 CEA LIST <gael.de-chalendar@cea.fr>
3//
4// SPDX-License-Identifier: MIT
5
15#ifndef XMLCONFIGURATIONFILEHANDLER_H
16#define XMLCONFIGURATIONFILEHANDLER_H
17
18#include "common/LimaCommon.h"
20
21#include <QtXml/QXmlDefaultHandler>
22
23#include <string>
24
25namespace Lima {
26namespace Common {
27namespace XMLConfigurationFiles {
28
34{
35public:
36 // -----------------------------------------------------------------------
37 // Constructors
38 // -----------------------------------------------------------------------
41
42 bool error(const QXmlParseException& e) override;
43 bool fatalError(const QXmlParseException& e) override;
44 bool warning(const QXmlParseException& e) override;
45
46 // -----------------------------------------------------------------------
47 // Implementations of the SAX DocumentHandler interface
48 // -----------------------------------------------------------------------
49 bool endElement(const QString & namespaceURI, const QString & name, const QString & qName) override;
50 bool startElement(const QString & namespaceURI, const QString & name, const QString & qName, const QXmlAttributes & attributes) override;
51
52private:
53 /*
54 * The current module group and, possibly, list
55 */
56 std::string m_moduleName;
57 std::string m_groupName;
58 std::string m_listName;
59 std::string m_mapName;
60
61 /*
62 * The structure where data will be stored
63 */
64 ConfigurationStructure& m_configuration;
65
67 std::string toString(const QString& str);
68};
69
70} // closing namespace XMLConfigurationFiles
71} // closing namespace Common
72} // closing namespace Lima
73
74#endif
#define LIMA_XMLCONFIGURATIONFILES_EXPORT
Definition LimaCommon.h:137
The instances of this class hold configuration informations of the modules Its design is currently ve...
This is a SAX document handler the configuration files.
originally detectConfigurationStructure.h in detectlibraries
NAUTITIA.