Correct use of ROOT_INCLUDE_DIR
[u/mrichter/AliRoot.git] / MUON / MUONmapping / AliMpDataProcessor.h
CommitLineData
228fd720 1/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
2 * See cxx source for full Copyright notice */
3
4// $Id$
5
6/// \ingroup basic
7/// \class AliMpDataProcessor
8/// \brief Class for converting ASCII data files in the map of string
9///
10/// \author Ivana Hrivnacova, IPN Orsay
11
12#ifndef ALI_MP_DATA_PROCESSOR_H
13#define ALI_MP_DATA_PROCESSOR_H
14
15#include <TObject.h>
16#include <TString.h>
17
18#include <fstream>
19
b80faac0 20using std::ofstream;
21
228fd720 22class AliMpDataMap;
23
24class AliMpDataProcessor : public TObject
25{
26 public:
27 AliMpDataProcessor();
28 virtual ~AliMpDataProcessor();
29
30 // methods
31 AliMpDataMap* CreateDataMap(const TString& dataDir = "data" );
32 Bool_t GenerateData(AliMpDataMap* dataMap,
33 const TString& outputDataDir = "data_new" );
34 Bool_t GenerateCode(AliMpDataMap* dataMap);
35
36 private:
31edb2d7 37 // static methods
38 static const TString& GetHeaderFileName();
39 static const TString& GetImplFileName();
40
228fd720 41 // methods
42 void ProcessDirectory(const TString& path, AliMpDataMap* map);
43 void ProcessFile(const TString& path, AliMpDataMap* map );
44 void GenerateFunction(const TString& path, const TString& data);
45 void GenerateFileCode(const TString& path);
46 void GenerateFill();
47
228fd720 48 // data
49 Int_t fCounter; ///< data files counter
50 ofstream fHeaderFile; ///< header file
51 ofstream fImplFile; ///< implementation file
52
53 ClassDef(AliMpDataProcessor,0) // Helper class for sorted integer array
54};
55
56#endif //ALI_MP_DATA_PROCESSOR_H
57