Jpp  18.3.0-rc.1
the software that should make you happy
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | List of all members
JAANET::JEvtWeighter Struct Reference

Look-up table for event weighters. More...

#include <JEvtWeightToolkit.hh>

Inheritance diagram for JAANET::JEvtWeighter:
std::vector< std::shared_ptr< JEvtWeight > >

Public Member Functions

 JEvtWeighter ()
 Constructor. More...
 
const JEvtWeightoperator() (const JHead &header) const
 Get event weighter corresponding to given header. More...
 

Detailed Description

Look-up table for event weighters.

Definition at line 51 of file JEvtWeightToolkit.hh.

Constructor & Destructor Documentation

JAANET::JEvtWeighter::JEvtWeighter ( )
inline

Constructor.

Definition at line 57 of file JEvtWeightToolkit.hh.

58  {
59  this->emplace_back(new JEvtWeightGSeaGen());
60  this->emplace_back(new JEvtWeightKM3BUU());
61  this->emplace_back(new JEvtWeightCorsika());
62  this->emplace_back(new JEvtWeightMupage());
63  this->emplace_back(new JEvtWeightDAQ());
64  this->emplace_back(new JEvtWeightMiscellaneous());
65  }
Implementation of event weighing for DAQ data.
Implementation of event weighing for miscellaneous data such as a merged offline file containing neut...
Implementation of event weighting for GSeaGen data.
Implementation of event weighting for KM3BUU data.
Implementation of event weighing for MUPAGE data.
Implementation of event weighting for Corsika data.

Member Function Documentation

const JEvtWeight& JAANET::JEvtWeighter::operator() ( const JHead header) const
inline

Get event weighter corresponding to given header.

Parameters
headerheader
Returns
event weighter

Definition at line 74 of file JEvtWeightToolkit.hh.

75  {
76  using namespace JPP;
77 
78  for (const_iterator i = this->begin(); i != this->end(); ++i) {
79 
80  if ((*i)->check(header)) {
81  return *(*i);
82  }
83  }
84 
85  THROW(JValueOutOfRange, "JEvtWeighter::operator(): No event weighter found for given header.");
86  }
#define THROW(JException_t, A)
Marco for throwing exception with std::ostream compatible message.
Definition: JException.hh:712

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