1 |
//--------------------------------------------------------------------------------------------------
|
2 |
// $Id: RunLumiRangeMap.h,v 1.1 2011/09/14 12:11:57 dkralph Exp $
|
3 |
//
|
4 |
// RunLumiRangeMap
|
5 |
//
|
6 |
// Stores a list of map of run numbers to lists of lumi section ranges
|
7 |
//
|
8 |
// Authors: J.Bendavid
|
9 |
//--------------------------------------------------------------------------------------------------
|
10 |
|
11 |
#ifndef RUNLUMIRANGEMAP_H
|
12 |
#define RUNLUMIRANGEMAP_H
|
13 |
|
14 |
#include <string>
|
15 |
#include <vector>
|
16 |
#include <map>
|
17 |
#include <TObject.h>
|
18 |
#include "RunLumiSet.h"
|
19 |
|
20 |
class RunLumiRangeMap : public TObject
|
21 |
{
|
22 |
public:
|
23 |
typedef std::pair<UInt_t,UInt_t> RunLumiPairType;
|
24 |
typedef std::map<UInt_t,std::vector<RunLumiPairType> > MapType;
|
25 |
|
26 |
RunLumiRangeMap() {}
|
27 |
RunLumiRangeMap(const RunLumiSet &rlset) { FillRunLumiSet(rlset); }
|
28 |
|
29 |
void AddJSONFile(const std::string &filepath);
|
30 |
void DumpJSONFile(const std::string &filepath);
|
31 |
Bool_t HasRunLumi(const RunLumiPairType &runLumi) const;
|
32 |
int Size();
|
33 |
|
34 |
protected:
|
35 |
void FillRunLumiSet(const RunLumiSet &rlSet);
|
36 |
|
37 |
MapType fMap; //mapped run-lumi ranges to accept
|
38 |
};
|
39 |
#endif
|