All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | Public Attributes | List of all members
EventInfoTree Struct Reference

Class managing the serialization of event information in a simple ROOT tree. More...

Inheritance diagram for EventInfoTree:
TreeHolder

Public Member Functions

 EventInfoTree (TTree &tree)
 Creates the required branches and assigns addresses to them. More...
 
void assignEvent (EventInfo_t const &info)
 Fills the information of the specified event. More...
 
- Public Member Functions inherited from TreeHolder
 TreeHolder ()=default
 
 TreeHolder (TTree &tree)
 
TTree & tree ()
 
TTree const & tree () const
 

Public Attributes

UInt_t fCC
 
UInt_t fNC
 
Int_t fIntType
 
Double_t fNuE
 
Double_t fOutLeptE
 
Double_t fTotE
 
Double_t fSpillE
 
Double_t fActiveE
 
Double_t fSpillActiveE
 
Bool_t fInActive
 

Detailed Description

Class managing the serialization of event information in a simple ROOT tree.

The tree is supplied by the caller. This object will create the proper branches into the tree and assign addresses to them. Then it will assume they will stay assigned.

On assignEvent(), the branch addresses are assigned the values from the event information. The tree is not Fill()-ed.

The tree structure is: CC/i:NC/i:IntType:I/NuE:D/OutLeptE:D/TotE/D:SpillE/D:InActive/O, with a single branch per element.

Branches:

Definition at line 518 of file TriggerEfficiencyPlots_module.cc.

Constructor & Destructor Documentation

EventInfoTree::EventInfoTree ( TTree &  tree)

Creates the required branches and assigns addresses to them.

Definition at line 2510 of file TriggerEfficiencyPlots_module.cc.

2510  : TreeHolder(tree) {
2511 
2512  this->tree().Branch("CC", &fCC);
2513  this->tree().Branch("NC", &fNC);
2514  this->tree().Branch("IntType", &fIntType);
2515  this->tree().Branch("NuE", &fNuE);
2516  this->tree().Branch("OutLeptE", &fOutLeptE);
2517 
2518  this->tree().Branch("TotE", &fTotE);
2519  this->tree().Branch("SpillE", &fSpillE);
2520  this->tree().Branch("ActiveE", &fActiveE);
2521  this->tree().Branch("SpillActiveE", &fSpillActiveE);
2522  this->tree().Branch("InActive", &fInActive);
2523 
2524 } // EventInfoTree::EventInfoTree()
TreeHolder()=default

Member Function Documentation

void EventInfoTree::assignEvent ( EventInfo_t const &  info)

Fills the information of the specified event.

Parameters
infoevent information to fill the tree with
inPlotswhether this event is plotted (as opposed to filtered out)

Definition at line 2528 of file TriggerEfficiencyPlots_module.cc.

2528  {
2529 
2530  fCC = info.nWeakChargedCurrentInteractions();
2531  fNC = info.nWeakNeutralCurrentInteractions();
2532  fIntType = info.InteractionType();
2533  fNuE = static_cast<Double_t>(info.NeutrinoEnergy());
2534  fOutLeptE = static_cast<Double_t>(info.LeptonEnergy());
2535 
2536  fTotE = static_cast<Double_t>(info.DepositedEnergy());
2537  fSpillE = static_cast<Double_t>(info.DepositedEnergyInSpill());
2538  fActiveE = static_cast<Double_t>(info.DepositedEnergyInActiveVolume());
2539  fSpillActiveE = static_cast<Double_t>(info.DepositedEnergyInSpillInActiveVolume());
2540  fInActive = static_cast<Bool_t>(info.isInActiveVolume());
2541 
2542 } // EventInfoTree::assignEvent()

Member Data Documentation

Double_t EventInfoTree::fActiveE

Definition at line 537 of file TriggerEfficiencyPlots_module.cc.

UInt_t EventInfoTree::fCC

Definition at line 530 of file TriggerEfficiencyPlots_module.cc.

Bool_t EventInfoTree::fInActive

Definition at line 540 of file TriggerEfficiencyPlots_module.cc.

Int_t EventInfoTree::fIntType

Definition at line 532 of file TriggerEfficiencyPlots_module.cc.

UInt_t EventInfoTree::fNC

Definition at line 531 of file TriggerEfficiencyPlots_module.cc.

Double_t EventInfoTree::fNuE

Definition at line 533 of file TriggerEfficiencyPlots_module.cc.

Double_t EventInfoTree::fOutLeptE

Definition at line 534 of file TriggerEfficiencyPlots_module.cc.

Double_t EventInfoTree::fSpillActiveE

Definition at line 538 of file TriggerEfficiencyPlots_module.cc.

Double_t EventInfoTree::fSpillE

Definition at line 536 of file TriggerEfficiencyPlots_module.cc.

Double_t EventInfoTree::fTotE

Definition at line 535 of file TriggerEfficiencyPlots_module.cc.


The documentation for this struct was generated from the following file: