CMS 3D CMS Logo

SaxToDom.h
Go to the documentation of this file.
1 #ifndef DETECTOR_DESCRIPTION_REGRESSION_TEST_SAXTODOM_H
2 #define DETECTOR_DESCRIPTION_REGRESSION_TEST_SAXTODOM_H
3 
4 #include <xercesc/util/XercesDefs.hpp>
5 #include <map>
6 #include <string>
7 #include <vector>
8 
12 #include "xercesc/sax/SAXParseException.hpp"
13 #include "xercesc/sax2/Attributes.hpp"
14 #include "xercesc/sax2/DefaultHandler.hpp"
15 #include "xercesc/util/XercesVersion.hpp"
16 
17 class SaxToDom : public XERCES_CPP_NAMESPACE::DefaultHandler {
18 public:
19  using Attributes = XERCES_CPP_NAMESPACE::Attributes;
20  using SAXParseException = XERCES_CPP_NAMESPACE::SAXParseException;
21  SaxToDom();
22  ~SaxToDom() override;
23  void startElement(const XMLCh* uri, const XMLCh* localname, const XMLCh* qname, const Attributes& attrs) override;
24  void endElement(const XMLCh* uri, const XMLCh* name, const XMLCh* qname) override;
25  const TinyDom& dom() const;
26 
27  // errors
28  void error(const SAXParseException& e) override;
29 
30 private:
31  std::vector<NodeName> parent_;
33 };
34 
35 #endif
SaxToDom::dom_
TinyDom dom_
Definition: SaxToDom.h:32
SaxToDom::Attributes
XERCES_CPP_NAMESPACE::Attributes Attributes
Definition: SaxToDom.h:19
SaxToDom::dom
const TinyDom & dom() const
Definition: SaxToDom.cc:16
SaxToDom::SAXParseException
XERCES_CPP_NAMESPACE::SAXParseException SAXParseException
Definition: SaxToDom.h:20
SaxToDom::parent_
std::vector< NodeName > parent_
Definition: SaxToDom.h:31
SaxToDom::error
void error(const SAXParseException &e) override
Definition: SaxToDom.cc:48
GraphWalker.h
SaxToDom::endElement
void endElement(const XMLCh *uri, const XMLCh *name, const XMLCh *qname) override
Definition: SaxToDom.cc:43
Graph.h
SaxToDom::SaxToDom
SaxToDom()
Definition: SaxToDom.cc:12
TinyDom.h
Skims_PA_cff.name
name
Definition: Skims_PA_cff.py:17
SaxToDom::~SaxToDom
~SaxToDom() override
Definition: SaxToDom.cc:14
math::Graph< NodeName, AttList >
SaxToDom
Definition: SaxToDom.h:17
SaxToDom::startElement
void startElement(const XMLCh *uri, const XMLCh *localname, const XMLCh *qname, const Attributes &attrs) override
Definition: SaxToDom.cc:18
MillePedeFileConverter_cfg.e
e
Definition: MillePedeFileConverter_cfg.py:37