GRSISort "v4.0.0.5"
An extension of the ROOT analysis Framework
Loading...
Searching...
No Matches
TimeWalkHelper.hh
Go to the documentation of this file.
1#ifndef TimeWalkHelper_h
2#define TimeWalkHelper_h
3
4// Header file for the classes stored in the TTree if any.
5#include "TGriffin.h"
6#include "TSceptar.h"
7#include "TGRSIHelper.h"
8
9class TimeWalkHelper : public TGRSIHelper, public ROOT::Detail::RDF::RActionImpl<TimeWalkHelper> {
10public:
11 explicit TimeWalkHelper(TList* list)
12 : TGRSIHelper(list)
13 {
14 Prefix("TimeWalk"); // Changes prefix of output file
15 Setup();
16 }
17 // These functions are expected to exist
18 ROOT::RDF::RResultPtr<std::map<std::string, TList>> Book(ROOT::RDataFrame* d) override
19 {
20 return d->Book<TGriffin, TSceptar>(std::move(*this), {"TGriffin", "TSceptar"});
21 }
22 void CreateHistograms(unsigned int slot) override;
23 void Exec(unsigned int slot, TGriffin& grif, TSceptar& scep);
24};
25
26// These are needed functions used by TDataFrameLibrary to create and destroy the instance of this helper
27extern "C" TimeWalkHelper* CreateHelper(TList* list) { return new TimeWalkHelper(list); }
28
29extern "C" void DestroyHelper(TGRSIHelper* helper) { delete helper; }
30
31#endif
void DestroyHelper(TGRSIHelper *helper)
TimeWalkHelper * CreateHelper(TList *list)
std::string & Prefix()
Definition TGRSIHelper.h:40
virtual void Setup()
void CreateHistograms(unsigned int slot) override
Virtual helper function that the user uses to create their histograms.
TimeWalkHelper(TList *list)
void Exec(unsigned int slot, TGriffin &grif, TSceptar &scep)
ROOT::RDF::RResultPtr< std::map< std::string, TList > > Book(ROOT::RDataFrame *d) override
This method will call the Book action on the provided dataframe.