CMS 3D CMS Logo

List of all members | Public Member Functions | Public Attributes
__class__Worker Struct Reference

#include <TSelector.h>

Public Member Functions

 __class__Worker (const TList *, TList &)
 
void postProcess (TList &)
 
void process (const edm::Event &iEvent)
 
 ~__class__Worker ()
 

Public Attributes

example_track TH1F * h_pt
 

Detailed Description

Definition at line 24 of file TSelector.h.

Constructor & Destructor Documentation

◆ __class__Worker()

__class__Worker::__class__Worker ( const TList *  fromSelector,
TList &  out 
)

Definition at line 46 of file TSelector.cc.

References h_pt, kPt, and MillePedeFileConverter_cfg::out.

46  {
47  //h_a = new TH1F( kA , "a" , 100, 0, 20 );
48  //out.Add(h_a);
49 @example_track h_pt = new TH1F(kPt, "P_t", 100, 0, 100);
50 @example_track out.Add(h_pt);
51 }
example_track example_track example_trackconst char *const kPt
Definition: TSelector.cc:34
example_track TH1F * h_pt
Definition: TSelector.h:31

◆ ~__class__Worker()

__class__Worker::~__class__Worker ( )

Definition at line 53 of file TSelector.cc.

53 {}

Member Function Documentation

◆ postProcess()

void __class__Worker::postProcess ( TList &  out)

Definition at line 76 of file TSelector.cc.

76 {}

◆ process()

void __class__Worker::process ( const edm::Event iEvent)

Definition at line 56 of file TSelector.cc.

References h_pt, iEvent, HLT_2022v11_cff::track, and tracks.

56  {
57  using namespace edm;
58 @example_track using reco::TrackCollection;
59 @example_track
60 @example_track Handle<TrackCollection> tracks;
61 @example_track iEvent.getByLabel("ctfWithMaterialTracks", tracks);
62 @example_track for (const auto& track : *tracks) {
63 @example_track h_pt->Fill(track.pt());
64 @example_track }
65 
66  //using namespace edmtest;
67  //edm::Handle<ThingCollection> hThings;
68  //iEvent.getByLabel("Thing", hThings);
69  //for (const auto& thing : *hThings) {
70  // h_a ->Fill(it->a);
71  //}
72 }
std::vector< Track > TrackCollection
collection of Tracks
Definition: TrackFwd.h:14
example_track TH1F * h_pt
Definition: TSelector.h:31
int iEvent
Definition: GenABIO.cc:224
auto const & tracks
cannot be loose
HLT enums.

Member Data Documentation

◆ h_pt

example_track TH1F* __class__Worker::h_pt

Definition at line 31 of file TSelector.h.

Referenced by __class__Worker(), and process().