ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
PhysicsAnalysis
D3PDTools
MultiDraw
MultiDraw
Formula.h
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3
*/
4
6
7
#ifndef MULTI_DRAW_FORMULA_H
8
#define MULTI_DRAW_FORMULA_H
9
11
12
13
14
//protect
15
#include <
MultiDraw/Global.h
>
16
17
#include <string>
18
#include <Rtypes.h>
19
20
class
TTree;
21
class
TTreeFormula;
22
class
TTreeFormulaManager;
23
24
namespace
MD
25
{
26
class
Formula
27
{
28
//
29
// public interface
30
//
31
34
public
:
35
void
testInvariant
()
const
;
36
37
40
public
:
41
Formula
();
42
43
47
public
:
48
Formula
(
const
std::string& name,
const
std::string&
formula
, TTree *
tree
);
49
50
53
public
:
54
~Formula
();
55
56
62
public
:
63
void
reset
(TTree *
tree
);
64
65
68
public
:
69
const
std::string&
formula
()
const
;
70
71
74
public
:
75
bool
valid
()
const
;
76
77
82
public
:
83
int
ndim
()
const
;
84
85
91
public
:
92
std::size_t
ndata
()
const
;
93
94
101
public
:
102
Double_t
value
(std::size_t data)
const
;
103
104
105
106
//
107
// private interface
108
//
109
111
private
:
112
std::string
m_formula
;
113
115
private
:
116
std::string
m_name
;
117
119
private
:
120
TTree *
m_tree
;
121
123
private
:
124
TTreeFormula *
m_form
;
125
127
private
:
128
TTreeFormulaManager *
m_manager
;
129
132
private
:
133
int
m_ndim
;
134
136
private
:
137
mutable
Long64_t
m_entry
;
138
140
private
:
141
mutable
Int_t
m_ndata
;
142
144
private
:
145
mutable
std::vector<Double_t>
m_cache
;
146
148
private
:
149
mutable
std::vector<bool>
m_read
;
150
151
153
private
:
154
Formula
(
const
Formula
& that);
155
Formula
&
operator =
(
const
Formula
& that);
156
};
157
}
158
159
#endif
Global.h
MD::Formula::formula
const std::string & formula() const
description: the formula used guarantee: no-fail
Definition
Formula.cxx:134
MD::Formula::ndim
int ndim() const
returns: the number of unspecified array dimensions for the given formula guarantee: no-fail requires...
Definition
Formula.cxx:152
MD::Formula::m_entry
Long64_t m_entry
description: the last entry we read
Definition
Formula.h:137
MD::Formula::testInvariant
void testInvariant() const
effects: test the invariant of this object guarantee: no-fail
Definition
Formula.cxx:32
MD::Formula::m_manager
TTreeFormulaManager * m_manager
description: the manager used
Definition
Formula.h:128
MD::Formula::m_form
TTreeFormula * m_form
description the formula used
Definition
Formula.h:124
MD::Formula::m_name
std::string m_name
description: the name we use for the formula
Definition
Formula.h:116
MD::Formula::m_tree
TTree * m_tree
description: the tree we are connected to
Definition
Formula.h:120
MD::Formula::~Formula
~Formula()
effects: standard destructor guarantee: no-fail
Definition
Formula.cxx:86
MD::Formula::Formula
Formula(const Formula &that)
rationale: to avoid broken objects
MD::Formula::m_ndim
int m_ndim
description: the number of array dimensions we need to loop over, or -1 if we are in error
Definition
Formula.h:133
MD::Formula::m_cache
std::vector< Double_t > m_cache
description: the cache of data entries
Definition
Formula.h:145
MD::Formula::valid
bool valid() const
returns: whether the formula is valid guarantee: no-fail
Definition
Formula.cxx:143
MD::Formula::ndata
std::size_t ndata() const
returns: the number of data entries for the formula with the given index guarantee: strong failures: ...
Definition
Formula.cxx:162
MD::Formula::value
Double_t value(std::size_t data) const
returns: the result of evaluating the formula with the given index for the given data entry guarantee...
Definition
Formula.cxx:195
MD::Formula::m_formula
std::string m_formula
description: members directly corresponding to accessors
Definition
Formula.h:112
MD::Formula::Formula
Formula()
effects: standard default constructor guarantee: no-fail
Definition
Formula.cxx:63
MD::Formula::operator=
Formula & operator=(const Formula &that)
MD::Formula::m_ndata
Int_t m_ndata
description: the number of data entries
Definition
Formula.h:141
MD::Formula::m_read
std::vector< bool > m_read
description: whether we read the given data entry
Definition
Formula.h:149
reset
const std::string reset
Definition
comparitor.cxx:61
MD
This module provides a lot of global definitions, forward declarations and includes that are used by ...
Definition
AlgCFlow.h:22
tree
TChain * tree
Definition
tile_monitor.h:30
Generated on
for ATLAS Offline Software by
1.17.0