KaliVeda
Toolkit for HIC analysis
KVFzDataReader.h
1 
4 #ifndef __KVFZDATAREADER_H
5 #define __KVFZDATAREADER_H
6 
7 #include "KVProtobufDataReader.h"
8 #include <KVUniqueNameList.h>
9 
10 #ifndef __CINT__
11 namespace DAQ {
12  class FzEvent;
13 }
14 #endif
15 
23 
24  KVUniqueNameList fListOfFiles;
25  std::unique_ptr<TIter> fFileListIterator;
26  KVString fFullFilePath;
27  int run_number;
28 
29  bool parse_event_from_message() override;
30  bool read_buffer() override;
31 
32 public:
34  KVFzDataReader(const Char_t* filepath, Int_t bufSiz = 16 * 1024 * 1024);
35  virtual ~KVFzDataReader()
36  {
37 #if ROOT_VERSION_CODE < ROOT_VERSION(6,0,0)
38  SafeDelete(fListOfFiles);
39  SafeDelete(fFileListIterator);
40 #endif
41  }
42 
43 #ifndef __CINT__
44  const DAQ::FzEvent& get_fazia_event() const;
45 #endif
46 
47  static KVFzDataReader* Open(const Char_t* filename, Option_t* opt = "");
48 
50  {
51  return run_number;
52  }
53 
54  ClassDefOverride(KVFzDataReader, 1) //Read FAZIA DAQ files
55 };
56 
57 #endif
int Int_t
#define SafeDelete(p)
char Char_t
const char Option_t
#define ClassDefOverride(name, id)
Handle FAZIA protobuf-format raw data files.
virtual ~KVFzDataReader()
Int_t GetRunNumberReadFromFile() const override
const DAQ::FzEvent & get_fazia_event() const
static KVFzDataReader * Open(const Char_t *filename, Option_t *opt="")
Read Google Protobuf DAQ files.
Extension of ROOT TString class which allows backwards compatibility with ROOT v3....
Definition: KVString.h:73
Optimised list in which named objects can only be placed once.