CMS 3D CMS Logo

EntryFinder.h
Go to the documentation of this file.
1 #ifndef DataFormats_FWLite_EntryFinder_h
2 #define DataFormats_FWLite_EntryFinder_h
3 // -*- C++ -*-
4 //
5 // Package: FWLite/DataFormats
6 // Class : EntryFinder
7 //
16 //
17 // Original Author: Bill Tanenbaum
18 //
19 // system include files
20 
21 // user include files
24 
25 // forward declarations
26 
27 namespace fwlite {
28  class BranchMapReader;
29  class EntryFinder {
30  public:
31  EntryFinder();
32  ~EntryFinder();
34  bool empty() const {return indexIntoFile_.empty() && fileIndex_.empty();}
35  EntryNumber_t findEvent(edm::RunNumber_t const& run, edm::LuminosityBlockNumber_t const& lumi, edm::EventNumber_t const& event) const;
36  EntryNumber_t findLumi(edm::RunNumber_t const& run, edm::LuminosityBlockNumber_t const& lumi) const;
37  EntryNumber_t findRun(edm::RunNumber_t const& run) const;
38  void fillIndex(BranchMapReader& branchMap);
39  static EntryNumber_t const invalidEntry = -1LL;
40  private:
43  };
44 }
45 #endif
bool empty() const
True if no runs, lumis, or events are in the file.
unsigned long long EventNumber_t
edm::IndexIntoFile indexIntoFile_
Definition: EntryFinder.h:41
unsigned int LuminosityBlockNumber_t
long long EntryNumber_t
EntryNumber_t findEvent(edm::RunNumber_t const &run, edm::LuminosityBlockNumber_t const &lumi, edm::EventNumber_t const &event) const
Definition: EntryFinder.cc:57
bool empty() const
Definition: FileIndex.h:112
edm::IndexIntoFile::EntryNumber_t EntryNumber_t
Definition: EntryFinder.h:33
EntryNumber_t findRun(edm::RunNumber_t const &run) const
Definition: EntryFinder.cc:91
void fillIndex(BranchMapReader &branchMap)
Definition: EntryFinder.cc:108
static EntryNumber_t const invalidEntry
Definition: EntryFinder.h:39
bool empty() const
Definition: EntryFinder.h:34
edm::FileIndex fileIndex_
Definition: EntryFinder.h:42
unsigned int RunNumber_t
Definition: event.py:1
EntryNumber_t findLumi(edm::RunNumber_t const &run, edm::LuminosityBlockNumber_t const &lumi) const
Definition: EntryFinder.cc:74