DD4hep  1.30.0
Detector Description Toolkit for High Energy Physics
config.h
Go to the documentation of this file.
1 //==========================================================================
2 // AIDA Detector description implementation
3 //--------------------------------------------------------------------------
4 // Copyright (C) Organisation europeenne pour la Recherche nucleaire (CERN)
5 // All rights reserved.
6 //
7 // For the licensing terms see $DD4hepINSTALL/LICENSE.
8 // For the list of contributors see $DD4hepINSTALL/doc/CREDITS.
9 //
10 // Author : M.Frank
11 //
12 //==========================================================================
13 //
14 // Setup XML parsing for the use of Apache Xerces-C and TiXml
15 //
16 //==========================================================================
17 #ifndef XML_CONFIG_H
18 #define XML_CONFIG_H
19 
20 #include <Parsers/config.h>
21 
22 #if defined(DD4HEP_USE_TINYXML)
23 #define __TIXML__
24 #endif
25 
26 // C/C++ include files
27 #include <cstdlib>
28 #include <cstdint>
29 
30 #ifndef __TIXML__
31 // This is the absolute minimal include necessary to comply with XercesC
32 // Not includuing this file leads to clashes in XmlChar aka XMLCh in XercesC.
33 //
34 // We do not load here many dependencies. This simply sets up primitive types.
35 #include <xercesc/util/Xerces_autoconf_config.hpp>
36 #endif
37 
39 namespace dd4hep {
40 
42  namespace xml {
43  class XmlElement;
44  class XmlDocument;
45  class XmlNodeList;
46  class XmlNode;
47  class XmlAttr;
48  typedef std::size_t XmlSize_t;
49 #ifdef __TIXML__
50  typedef char XmlChar;
51 #else
52  typedef XERCES_XMLCH_T XmlChar;
54  // These only work for very specific XercesC implementations:
55  //typedef char16_t XmlChar;
56  //typedef unsigned short XmlChar;
57 #endif
58  }
59 }
60 
61 #ifdef __TIXML__
62 #define XML_IMPLEMENTATION_TYPE " TinyXML DOM mini-parser "
63 #else // Xerces-C
64 #define XML_IMPLEMENTATION_TYPE " Apache Xerces-C DOM Parser"
65 #endif // __TIXML__
66 #endif // XML_CONFIG_H
dd4hep::xml
Namespace for the AIDA detector description toolkit supporting XML utilities.
Definition: ConditionsTags.h:27
dd4hep::xml::XmlChar
XERCES_XMLCH_T XmlChar
Use the definition from the autoconf header of Xerces:
Definition: config.h:53
dd4hep
Namespace for the AIDA detector description toolkit.
Definition: AlignmentsCalib.h:28
dd4hep::xml::XmlSize_t
std::size_t XmlSize_t
Definition: config.h:47