#include <RecoPixelVertexing/PixelVertexFinding/SkipBadEvents.h>
Public Member Functions | |
virtual bool | filter (edm::Event &e, const edm::EventSetup &s) |
SkipBadEvents (const edm::ParameterSet &config) | |
virtual | ~SkipBadEvents () |
Private Attributes | |
std::map< int, std::set< int > > | skip_ |
This won't be needed when PoolSource can do this for us, then I will retire this little guy.
Definition at line 20 of file SkipBadEvents.h.
SkipBadEvents::SkipBadEvents | ( | const edm::ParameterSet & | config | ) | [explicit] |
Definition at line 3 of file SkipBadEvents.cc.
References edm::ParameterSet::getParameter(), i, and skip_.
00003 { 00004 std::vector<int> badrunevent = config.getParameter<std::vector<int> >("RunEvent"); 00005 // Convert to a map for easy lookup 00006 for (unsigned int i=0; i<badrunevent.size(); i+=2) { 00007 skip_[ badrunevent[i] ].insert( badrunevent[i+1] ); 00008 } 00009 }
SkipBadEvents::~SkipBadEvents | ( | ) | [virtual] |
bool SkipBadEvents::filter | ( | edm::Event & | e, | |
const edm::EventSetup & | s | |||
) | [virtual] |
Implements edm::EDFilter.
Definition at line 13 of file SkipBadEvents.cc.
References edm::Event::id(), mergeAndRegister_online::run, and skip_.
00013 { 00014 int run = e.id().run(); 00015 int evt = e.id().event(); 00016 00017 bool pass = ( skip_[run].find(evt) == skip_[run].end() ); 00018 00019 return pass; 00020 }
std::map<int,std::set<int> > SkipBadEvents::skip_ [private] |