1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
|
#ifndef DataFormats_FWLite_EntryFinder_h
#define DataFormats_FWLite_EntryFinder_h
// -*- C++ -*-
//
// Package: FWLite/DataFormats
// Class : EntryFinder
//
/**\class DataFormats/FWLite/interface/EntryFinder.h
Description: <one line class summary>
Usage:
<usage>
*/
//
// Original Author: Bill Tanenbaum
//
// system include files
// user include files
#include "DataFormats/Provenance/interface/FileIndex.h"
#include "DataFormats/Provenance/interface/IndexIntoFile.h"
// forward declarations
namespace fwlite {
class BranchMapReader;
class EntryFinder {
public:
EntryFinder();
~EntryFinder();
typedef edm::IndexIntoFile::EntryNumber_t EntryNumber_t;
bool empty() const { return indexIntoFile_.empty() && fileIndex_.empty(); }
EntryNumber_t findEvent(edm::RunNumber_t const& run,
edm::LuminosityBlockNumber_t const& lumi,
edm::EventNumber_t const& event) const;
EntryNumber_t findLumi(edm::RunNumber_t const& run, edm::LuminosityBlockNumber_t const& lumi) const;
EntryNumber_t findRun(edm::RunNumber_t const& run) const;
void fillIndex(BranchMapReader& branchMap);
static EntryNumber_t const invalidEntry = -1LL;
private:
edm::IndexIntoFile indexIntoFile_;
edm::FileIndex fileIndex_;
};
} // namespace fwlite
#endif
|