#include <ThingsTSelector.h>
Definition at line 16 of file ThingsTSelector.h.
tfwliteselectortest::ThingsTSelector::ThingsTSelector |
( |
| ) |
|
|
inline |
Definition at line 18 of file ThingsTSelector.h.
edm::propagate_const< TH1F * > h_a
histograms
edm::propagate_const< TH1F * > h_refA
tfwliteselectortest::ThingsTSelector::ThingsTSelector |
( |
ThingsTSelector const & |
| ) |
|
|
private |
void ThingsTSelector::begin |
( |
TList *& |
in | ) |
|
|
virtual |
Called each time the 'client' begins processing (remote 'slaves' do not see this message)
- Parameters
-
in | an assignable pointer to a list of objects you want passed to 'preProcessing'. This list is used to communicate with remote slaves. NOTE: you are responsible for deleting this TList and its content once you are done with it. |
Implements TFWLiteSelectorBasic.
Definition at line 14 of file ThingsTSelector.cc.
void ThingsTSelector::postProcessing |
( |
TList & |
out | ) |
|
|
virtual |
Called each time the 'slave' has seen all the events
- Parameters
-
out | the list of objects that will be sent to 'terminate'. You can Add() additional objects to 'out' at this point as well. |
Implements TFWLiteSelectorBasic.
Definition at line 76 of file ThingsTSelector.cc.
void ThingsTSelector::preProcessing |
( |
const TList * |
in, |
|
|
TList & |
out |
|
) |
| |
|
virtual |
Called each time the 'slave' is about to start processing
- Parameters
-
in | a pointer to the list of objects created in 'begin()'. The pointer can be 0 |
out | a list of objects that are the result of processing (e.g. histograms). You should call 'Add()' for each object you want sent to the 'terminate' method. |
Implements TFWLiteSelectorBasic.
Definition at line 18 of file ThingsTSelector.cc.
References edm::propagate_const< T >::get(), h_a, h_refA, kA, and kRefA.
24 h_a =
new TH1F(
kA ,
"a" , 100, 0, 20 );
static const char * kRefA
edm::propagate_const< TH1F * > h_a
histograms
edm::propagate_const< TH1F * > h_refA
element_type const * get() const
void ThingsTSelector::process |
( |
const edm::Event & |
event | ) |
|
|
virtual |
Call each time the 'slave' gets a new Event
- Parameters
-
event | a standard edm::Event which works just like it does in cmsRun |
Implements TFWLiteSelectorBasic.
Definition at line 36 of file ThingsTSelector.cc.
References gather_cfg::cout, cppFunctionSkipper::exception, edm::Event::getByLabel(), h_a, h_refA, i, cms::Exception::what(), and x().
Referenced by ConfigBuilder.ConfigBuilder::addExtraStream(), ConfigBuilder.ConfigBuilder::completeInputCommand(), ConfigBuilder.ConfigBuilder::doNotInlineEventContent(), ConfigBuilder.ConfigBuilder.PrintAllModules::leave(), ConfigBuilder.ConfigBuilder::prepare_HLT(), ConfigBuilder.ConfigBuilder::prepare_LHE(), ConfigBuilder.ConfigBuilder::prepare_PATFILTER(), ConfigBuilder.ConfigBuilder::prepare_VALIDATION(), ConfigBuilder.ConfigBuilder::renameHLTprocessInSequence(), ConfigBuilder.ConfigBuilder::renameInputTagsInSequence(), and ConfigBuilder.ConfigBuilder::scheduleSequence().
37 std::cout <<
"processing event " << std::endl;
39 using namespace edmtest;
43 iEvent.getByLabel(
"OtherThing",
"testUserTag", hOThings);
44 std::cout <<
">> other things found:" << hOThings->size() << std::endl;
46 for (
size_t i = 0;
i < hOThings->size(); ++
i ) {
47 const OtherThing & thing = (*hOThings)[
i ];
48 h_refA ->Fill( thing.ref->a );
49 std::cout <<
">> ref->a: " << thing.ref->a << std::endl;
53 iEvent.getByLabel(
"Thing",hThings);
54 const ThingCollection& things = *hThings;
55 std::cout <<
">> things found:" << things.size() << std::endl;
56 for (
size_t i = 0;
i < things.size(); ++
i ) {
57 const Thing & thing = things[
i ];
58 h_a ->Fill( thing.a );
59 std::cout <<
">> a: " << thing.a << std::endl;
62 std::cout << std::endl <<
"Failed with cms::Exception: " << std::endl;
66 std::cout << std::endl <<
"Failed with std::exception" << std::endl;
70 std::cout << std::endl <<
"Failed with unknown exception" << std::endl;
virtual char const * what() const
edm::propagate_const< TH1F * > h_a
histograms
edm::propagate_const< TH1F * > h_refA
void ThingsTSelector::terminate |
( |
TList & |
out | ) |
|
|
virtual |