Jpp  18.5.0
the software that should make you happy
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
JEvtWeightInterface.hh
Go to the documentation of this file.
1 #ifndef __JAANET__JEVTWEIGHTINTERFACE__
2 #define __JAANET__JEVTWEIGHTINTERFACE__
3 
6 
7 #include "JAAnet/JHead.hh"
8 
9 
10 /**
11  * \author mdejong
12  */
13 
14 namespace JAANET {}
15 namespace JPP { using namespace JAANET; }
16 
17 namespace JAANET {
18 
19  /**
20  * Low-level interface for event weighing.
21  */
23  {
24  /**
25  * Configuration.
26  *
27  * \param header header
28  */
29  virtual void configure(const JHead& header) = 0;
30 
31 
32  /**
33  * Check whether header is consistent with this event weighter.
34  *
35  * \param header header
36  * \return true if consistent; else false
37  */
38  virtual bool check(const JHead& header) const = 0;
39 
40 
41  /**
42  * Get weight of given event.
43  *
44  * \param evt event
45  * \return weight [Hz]
46  */
47  virtual double getWeight(const Evt& evt) const = 0;
48 
49 
50  /**
51  * Get event-weight normalisation factor.
52  * Note: the return-value should be *multiplied* in order to normalise the event-weight
53  *
54  * \return event-weight normalisation factor.
55  */
56  virtual double getNormalisation() const = 0;
57  };
58 }
59 
60 #endif
virtual double getNormalisation() const =0
Get event-weight normalisation factor.
virtual bool check(const JHead &header) const =0
Check whether header is consistent with this event weighter.
Low-level interface for event weighing.
Monte Carlo run header.
Definition: JHead.hh:1234
virtual double getWeight(const Evt &evt) const =0
Get weight of given event.
virtual void configure(const JHead &header)=0
Configuration.
The Evt class respresent a Monte Carlo (MC) event as well as an offline event.
Definition: Evt.hh:20