test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
XMLConfigWriter.h
Go to the documentation of this file.
1 #ifndef OMTF_XMLConfigWriter_H
2 #define OMTF_XMLConfigWriter_H
3 
4 #include <string>
5 #include <vector>
6 
7 #include "xercesc/util/XercesDefs.hpp"
8 
10 
11 class GoldenPattern;
12 class OMTFConfiguration;
13 class OMTFinput;
14 class OMTFResult;
15 class AlgoMuon;
16 struct Key;
17 
18 namespace XERCES_CPP_NAMESPACE{
19  class DOMElement;
20  class DOMDocument;
21  class DOMImplementation;
22 }
23 
25 
26  public:
27 
28  XMLConfigWriter(const OMTFConfiguration* aOMTFConfig);
29 
30  void initialiseXMLDocument(const std::string & docName);
31 
33 
34  xercesc::DOMElement * writeEventHeader(unsigned int eventId,
35  unsigned int mixedEventId = 0);
36 
37  xercesc::DOMElement * writeEventData(xercesc::DOMElement *aTopElement,
38  unsigned int iProcessor,
39  const OMTFinput & aInput);
40 
41  void writeCandidateData(xercesc::DOMElement *aTopElement,
42  unsigned int iRefHit,
43  const AlgoMuon & aCand);
44 
45  void writeResultsData(xercesc::DOMElement *aTopElement,
46  unsigned int iRegion,
47  const Key& aKey,
48  const OMTFResult & aResult);
49 
50  void writeGPData(const GoldenPattern & aGP);
51 
52  void writeGPData(const GoldenPattern & aGP1,
53  const GoldenPattern & aGP2,
54  const GoldenPattern & aGP3,
55  const GoldenPattern & aGP4);
56 
57  void writeConnectionsData(const std::vector<std::vector <OMTFConfiguration::vector2D> > & measurements4D);
58 
59  unsigned int findMaxInput(const OMTFConfiguration::vector1D & myCounts);
60 
61  private:
62 
63  xercesc::DOMImplementation* domImpl;
64  xercesc::DOMElement* theTopElement;
65  xercesc::DOMDocument* theDoc;
66 
68 
69 };
70 
71 
74 #endif
void writeConnectionsData(const std::vector< std::vector< OMTFConfiguration::vector2D > > &measurements4D)
XMLConfigWriter(const OMTFConfiguration *aOMTFConfig)
void initialiseXMLDocument(const std::string &docName)
xercesc::DOMElement * writeEventData(xercesc::DOMElement *aTopElement, unsigned int iProcessor, const OMTFinput &aInput)
void writeResultsData(xercesc::DOMElement *aTopElement, unsigned int iRegion, const Key &aKey, const OMTFResult &aResult)
unsigned int findMaxInput(const OMTFConfiguration::vector1D &myCounts)
std::vector< int > vector1D
xercesc::DOMImplementation * domImpl
const OMTFConfiguration * myOMTFConfig
void finaliseXMLDocument(const std::string &fName)
xercesc::DOMElement * writeEventHeader(unsigned int eventId, unsigned int mixedEventId=0)
xercesc::DOMDocument * theDoc
xercesc::DOMElement * theTopElement
void writeCandidateData(xercesc::DOMElement *aTopElement, unsigned int iRefHit, const AlgoMuon &aCand)
void writeGPData(const GoldenPattern &aGP)