Public Member Functions | |
RawDataSelector (const edm::ParameterSet &) | |
~RawDataSelector () | |
Private Member Functions | |
virtual void | produce (edm::Event &, const edm::EventSetup &) override |
Private Attributes | |
edm::InputTag | dataLabel |
std::pair< int, int > | fedRange |
RawDataFEDSelector * | selector |
Definition at line 22 of file RawDataSelector.cc.
RawDataSelector::RawDataSelector | ( | const edm::ParameterSet & | pset | ) | [explicit] |
Definition at line 41 of file RawDataSelector.cc.
References fedRange, edm::ParameterSet::getParameter(), and selector.
: dataLabel(pset.getUntrackedParameter<edm::InputTag>("InputLabel",edm::InputTag("source"))) { fedRange = std::pair<int,int>(pset.getParameter<int>("lowerBound"), pset.getParameter<int>("upperBound")); selector = new RawDataFEDSelector(); produces<FEDRawDataCollection>(); }
RawDataSelector::~RawDataSelector | ( | ) |
void RawDataSelector::produce | ( | edm::Event & | iEvent, |
const edm::EventSetup & | iSetup | ||
) | [override, private, virtual] |
Implements edm::EDProducer.
Definition at line 58 of file RawDataSelector.cc.
References dataLabel, fedRange, edm::Event::getByLabel(), edm::Event::put(), RawDataFEDSelector::select(), and selector.
{ using namespace edm; using namespace std; Handle<FEDRawDataCollection> rawData; iEvent.getByLabel( dataLabel, rawData); /* here eventually perform some operation to get the list of FED's to be written in the new collection. In this case we simply take the range from the ParameterSet */ // the filtered raw data collections auto_ptr<FEDRawDataCollection> selectedRawData = selector->select(rawData, fedRange); iEvent.put(selectedRawData); }
edm::InputTag RawDataSelector::dataLabel [private] |
Definition at line 36 of file RawDataSelector.cc.
Referenced by produce().
std::pair<int,int> RawDataSelector::fedRange [private] |
Definition at line 37 of file RawDataSelector.cc.
Referenced by produce(), and RawDataSelector().
RawDataFEDSelector* RawDataSelector::selector [private] |
Definition at line 34 of file RawDataSelector.cc.
Referenced by produce(), RawDataSelector(), and ~RawDataSelector().