Logo ROOT  
Reference Guide
TTreeFormula.h
Go to the documentation of this file.
1 // @(#)root/treeplayer:$Id$
2 // Author: Rene Brun 19/01/96
3 
4 /*************************************************************************
5  * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *
6  * All rights reserved. *
7  * *
8  * For the licensing terms see $ROOTSYS/LICENSE. *
9  * For the list of contributors see $ROOTSYS/README/CREDITS. *
10  *************************************************************************/
11 // ---------------------------------- TreeFormula.h
12 
13 #ifndef ROOT_TTreeFormula
14 #define ROOT_TTreeFormula
15 
16 
17 
18 //////////////////////////////////////////////////////////////////////////
19 // //
20 // TTreeFormula //
21 // //
22 // The Tree formula class //
23 // //
24 //////////////////////////////////////////////////////////////////////////
25 
26 #include "v5/TFormula.h"
27 
28 #include "TLeaf.h"
29 
30 #include "TObjArray.h"
31 
32 #include <string>
33 #include <vector>
34 
35 #ifdef R__OLDHPACC
36 namespace std {
37  using ::string;
38  using ::vector;
39 }
40 #endif
41 
42 const Int_t kMAXCODES = kMAXFOUND; // must be the same as kMAXFOUND in TFormulaOld
43 const Int_t kMAXFORMDIM = 5; // Maximum number of array dimensions support in TTreeFormula
44 
45 class TTree;
46 class TArrayI;
47 class TMethodCall;
48 class TLeafObject;
49 class TDataMember;
50 class TStreamerElement;
52 class TFormLeafInfo;
53 class TBranchElement;
54 class TAxis;
56 
57 
59 
60 friend class TTreeFormulaManager;
61 
62 protected:
63  enum EStatusBits {
65  kMissingLeaf = BIT(15), // true if some of the needed leaves are missing in the current TTree
66  kIsInteger = BIT(17), // true if the branch contains an integer variable
67  kNeedEntries = BIT(18) // true if the formula uses Entries$
68  };
69  enum {
76 
77  };
78  enum {
79  kAlias = 200,
80  kAliasString = 201,
81  kAlternate = 202,
83  kMinIf = 204,
84  kMaxIf = 205
85  };
86 
87  // Helper struct to hold a cache
88  // that can accelerate calculation of the RealIndex.
93  };
94 
95  TTree *fTree; //! pointer to Tree
96  Int_t fCodes[kMAXCODES]; // List of leaf numbers referenced in formula
97  Int_t fNdata[kMAXCODES]; //! This caches the physical number of element in the leaf or data member.
98  Int_t fNcodes; // Number of leaves referenced in formula
99  Bool_t fHasCast; // Record whether the formula contain a cast operation or not
100  Int_t fMultiplicity; // Indicator of the variability of the formula
101  Int_t fNindex; // Size of fIndex
102  Int_t *fLookupType; //[fNindex] array indicating how each leaf should be looked-up
103  TObjArray fLeaves; //! List of leaf used in this formula.
104  TObjArray fDataMembers; //! List of leaf data members
105  TObjArray fMethods; //! List of leaf method calls
106  TObjArray fExternalCuts; //! List of TCutG and TEntryList used in the formula
107  TObjArray fAliases; //! List of TTreeFormula for each alias used.
108  TObjArray fLeafNames; // List of TNamed describing leaves
109  TObjArray fBranches; //! List of branches to read. Similar to fLeaves but duplicates are zeroed out.
110  Bool_t fQuickLoad; //! If true, branch GetEntry is only called when the entry number changes.
111  Bool_t fNeedLoading; //! If true, the current entry has not been loaded yet.
112 
113  Int_t fNdimensions[kMAXCODES]; //Number of array dimensions in each leaf
114  Int_t fFixedSizes[kMAXCODES][kMAXFORMDIM]; //Physical sizes of lower dimensions for each leaf
115  UChar_t fHasMultipleVarDim[kMAXCODES]; //True if the corresponding variable is an array with more than one variable dimension.
116 
117  //the next line should have a mutable in front. See GetNdata()
118  Int_t fCumulSizes[kMAXCODES][kMAXFORMDIM]; //Accumulated sizes of lower dimensions for each leaf after variable dimensions has been calculated
119  Int_t fIndexes[kMAXCODES][kMAXFORMDIM]; //Index of array selected by user for each leaf
120  TTreeFormula *fVarIndexes[kMAXCODES][kMAXFORMDIM]; //Pointer to a variable index.
121 
122  TAxis *fAxis; //! pointer to histogram axis if this is a string
123  Bool_t fDidBooleanOptimization; //! True if we executed one boolean optimization since the last time instance number 0 was evaluated
124  TTreeFormulaManager *fManager; //! The dimension coordinator.
125 
126  // Helper members and function used during the construction and parsing
127  TList *fDimensionSetup; //! list of dimension setups, for delayed creation of the dimension information.
128  std::vector<std::string> fAliasesUsed; //! List of aliases used during the parsing of the expression.
129 
130  LongDouble_t* fConstLD; //! local version of fConsts able to store bigger numbers
131 
132  RealInstanceCache fRealInstanceCache; //! Cache accelerating the GetRealInstance function
133 
134  TTreeFormula(const char *name, const char *formula, TTree *tree, const std::vector<std::string>& aliases);
135  void Init(const char *name, const char *formula);
136  Bool_t BranchHasMethod(TLeaf* leaf, TBranch* branch, const char* method,const char* params, Long64_t readentry) const;
137  Int_t DefineAlternate(const char* expression);
138  void DefineDimensions(Int_t code, Int_t size, TFormLeafInfoMultiVarDim * info, Int_t& virt_dim);
139  Int_t FindLeafForExpression(const char* expression, TLeaf *&leaf, TString &leftover, Bool_t &final, UInt_t &paran_level, TObjArray &castqueue, std::vector<std::string>& aliasUsed, Bool_t &useLeafCollectionObject, const char *fullExpression);
140  TLeaf* GetLeafWithDatamember(const char* topchoice, const char* nextchice, Long64_t readentry) const;
141  Int_t ParseWithLeaf(TLeaf *leaf, const char *expression, Bool_t final, UInt_t paran_level, TObjArray &castqueue, Bool_t useLeafCollectionObject, const char *fullExpression);
142  Int_t RegisterDimensions(Int_t code, Int_t size, TFormLeafInfoMultiVarDim * multidim = 0);
144  Int_t RegisterDimensions(Int_t code, TFormLeafInfo *info, TFormLeafInfo *maininfo, Bool_t useCollectionObject);
145  Int_t RegisterDimensions(Int_t code, TLeaf *leaf);
146  Int_t RegisterDimensions(const char *size, Int_t code);
147 
148  virtual Double_t GetValueFromMethod(Int_t i, TLeaf *leaf) const;
149  virtual void* GetValuePointerFromMethod(Int_t i, TLeaf *leaf) const;
151 
152  void LoadBranches();
154  void ResetDimensions();
155 
156  virtual TClass* EvalClass(Int_t oper) const;
157  virtual Bool_t IsLeafInteger(Int_t code) const;
158  virtual Bool_t IsString(Int_t oper) const;
159  virtual Bool_t IsLeafString(Int_t code) const;
160  virtual Bool_t SwitchToFormLeafInfo(Int_t code);
161  virtual Bool_t StringToNumber(Int_t code);
162 
163  void Convert(UInt_t fromVersion);
164 
165 private:
166  // Not implemented yet
167  TTreeFormula(const TTreeFormula&) = delete;
169 
170  template<typename T> T GetConstant(Int_t k);
171 
172 public:
173  TTreeFormula();
174  TTreeFormula(const char *name,const char *formula, TTree *tree);
175  virtual ~TTreeFormula();
176 
177  virtual Int_t DefinedVariable(TString &variable, Int_t &action);
178  virtual TClass* EvalClass() const;
179 
180  template<typename T> T EvalInstance(Int_t i=0, const char *stringStack[]=0);
181  virtual Double_t EvalInstance(Int_t i=0, const char *stringStack[]=0) {return EvalInstance<Double_t>(i, stringStack); }
182  virtual Long64_t EvalInstance64(Int_t i=0, const char *stringStack[]=0) {return EvalInstance<Long64_t>(i, stringStack); }
183  virtual LongDouble_t EvalInstanceLD(Int_t i=0, const char *stringStack[]=0) {return EvalInstance<LongDouble_t>(i, stringStack); }
184 
185  virtual const char *EvalStringInstance(Int_t i=0);
186  virtual void* EvalObject(Int_t i=0);
187  // EvalInstance should be const. See comment on GetNdata()
188  TFormLeafInfo *GetLeafInfo(Int_t code) const;
190  TMethodCall *GetMethodCall(Int_t code) const;
191  virtual Int_t GetMultiplicity() const {return fMultiplicity;}
192  virtual TLeaf *GetLeaf(Int_t n) const;
193  virtual Int_t GetNcodes() const {return fNcodes;}
194  virtual Int_t GetNdata();
195  //GetNdata should probably be const. However it need to cache some information about the actual dimension
196  //of arrays, so if GetNdata is const, the variables fUsedSizes and fCumulUsedSizes need to be declared
197  //mutable. We will be able to do that only when all the compilers supported for ROOT actually implemented
198  //the mutable keyword.
199  //NOTE: Also modify the code in PrintValue which current goes around this limitation :(
200  virtual Bool_t IsInteger(Bool_t fast=kTRUE) const;
201  Bool_t IsQuickLoad() const { return fQuickLoad; }
202  virtual Bool_t IsString() const;
203  virtual Bool_t Notify() { UpdateFormulaLeaves(); return kTRUE; }
204  virtual char *PrintValue(Int_t mode=0) const;
205  virtual char *PrintValue(Int_t mode, Int_t instance, const char *decform = "9.9") const;
206  virtual void SetAxis(TAxis *axis=0);
207  void SetQuickLoad(Bool_t quick) { fQuickLoad = quick; }
208  virtual void SetTree(TTree *tree) {fTree = tree;}
209  virtual void ResetLoading();
210  virtual TTree* GetTree() const {return fTree;}
211  virtual void UpdateFormulaLeaves();
212 
213  ClassDef(TTreeFormula, 10); //The Tree formula
214 };
215 
216 #endif
TTreeFormula::GetLeafInfo
TFormLeafInfo * GetLeafInfo(Int_t code) const
Return DataMember corresponding to code.
Definition: TTreeFormula.cxx:4415
TTreeFormula::fQuickLoad
Bool_t fQuickLoad
List of branches to read. Similar to fLeaves but duplicates are zeroed out.
Definition: TTreeFormula.h:110
TTreeFormula::fDimensionSetup
TList * fDimensionSetup
The dimension coordinator.
Definition: TTreeFormula.h:127
n
const Int_t n
Definition: legend1.C:16
TAxis
Class to manage histogram axis.
Definition: TAxis.h:30
TTreeFormula::GetConstant
T GetConstant(Int_t k)
Definition: TTreeFormula.cxx:3909
TTreeFormula::kIsCharacter
@ kIsCharacter
Definition: TTreeFormula.h:64
TTreeFormula::DefineDimensions
void DefineDimensions(Int_t code, Int_t size, TFormLeafInfoMultiVarDim *info, Int_t &virt_dim)
This method is used internally to decode the dimensions of the variables.
Definition: TTreeFormula.cxx:356
TTreeFormula::fLookupType
Int_t * fLookupType
Definition: TTreeFormula.h:102
TTreeFormula::RealInstanceCache::fInstanceCache
Int_t fInstanceCache
Definition: TTreeFormula.h:90
TTreeFormula::EvalObject
virtual void * EvalObject(Int_t i=0)
Evaluate this treeformula.
Definition: TTreeFormula.cxx:3642
TTreeFormula::SetQuickLoad
void SetQuickLoad(Bool_t quick)
Definition: TTreeFormula.h:207
kTRUE
const Bool_t kTRUE
Definition: RtypesCore.h:91
TTreeFormula::kAlternate
@ kAlternate
Definition: TTreeFormula.h:81
TTreeFormula::IsInteger
virtual Bool_t IsInteger(Bool_t fast=kTRUE) const
Return TRUE if the formula corresponds to one single Tree leaf and this leaf is short,...
Definition: TTreeFormula.cxx:4582
TTreeFormula::EvalInstance64
virtual Long64_t EvalInstance64(Int_t i=0, const char *stringStack[]=0)
Definition: TTreeFormula.h:182
TTreeFormula::fNdata
Int_t fNdata[kMAXCODES]
Definition: TTreeFormula.h:97
TObjArray
An array of TObjects.
Definition: TObjArray.h:37
TTreeFormula::kIndexOfLocalEntry
@ kIndexOfLocalEntry
Definition: TTreeFormula.h:73
TTreeFormula::fMethods
TObjArray fMethods
List of leaf data members.
Definition: TTreeFormula.h:105
TTreeFormula::fMultiplicity
Int_t fMultiplicity
Definition: TTreeFormula.h:100
TTreeFormula::kMax
@ kMax
Definition: TTreeFormula.h:74
TTreeFormula::RealInstanceCache::fVirtAccumCache
Int_t fVirtAccumCache
Definition: TTreeFormula.h:92
TTreeFormula::operator=
TTreeFormula & operator=(const TTreeFormula &)=delete
TTreeFormula::fFixedSizes
Int_t fFixedSizes[kMAXCODES][kMAXFORMDIM]
Definition: TTreeFormula.h:114
TTreeFormula::RealInstanceCache
Definition: TTreeFormula.h:89
TBranchElement
A Branch for the case of an object.
Definition: TBranchElement.h:39
TTreeFormula::fCodes
Int_t fCodes[kMAXCODES]
pointer to Tree
Definition: TTreeFormula.h:96
TTreeFormula::SetAxis
virtual void SetAxis(TAxis *axis=0)
Set the axis (in particular get the type).
Definition: TTreeFormula.cxx:4978
tree
Definition: tree.py:1
TTreeFormula::fExternalCuts
TObjArray fExternalCuts
List of leaf method calls.
Definition: TTreeFormula.h:106
TTreeFormula::kIsInteger
@ kIsInteger
Definition: TTreeFormula.h:66
TTreeFormula::ResetDimensions
void ResetDimensions()
Populate the TTreeFormulaManager with the dimension information.
Definition: TTreeFormula.cxx:5146
TTreeFormula::ResetLoading
virtual void ResetLoading()
Tell the formula that we are going to request a new entry.
Definition: TTreeFormula.cxx:4940
TTreeFormula::Convert
void Convert(UInt_t fromVersion)
Definition: TTreeFormula.cxx:5625
Long64_t
long long Long64_t
Definition: RtypesCore.h:73
TTreeFormula::SwitchToFormLeafInfo
virtual Bool_t SwitchToFormLeafInfo(Int_t code)
Convert the underlying lookup method from the direct technique (dereferencing the address held by the...
Definition: TTreeFormula.cxx:5673
TTreeFormula::kMinIf
@ kMinIf
Definition: TTreeFormula.h:83
TTree
A TTree represents a columnar dataset.
Definition: TTree.h:79
TTreeFormula::kMin
@ kMin
Definition: TTreeFormula.h:74
TTreeFormula::GetManager
TTreeFormulaManager * GetManager() const
Definition: TTreeFormula.h:189
TTreeFormula::kEntryList
@ kEntryList
Definition: TTreeFormula.h:71
TTreeFormula::IsLeafString
virtual Bool_t IsLeafString(Int_t code) const
Return TRUE if the leaf or data member corresponding to code is a string.
Definition: TTreeFormula.cxx:4707
Int_t
int Int_t
Definition: RtypesCore.h:45
TDataMember
All ROOT classes may have RTTI (run time type identification) support added.
Definition: TDataMember.h:31
TTreeFormula::fBranches
TObjArray fBranches
Definition: TTreeFormula.h:109
TTreeFormula::EvalInstance
virtual Double_t EvalInstance(Int_t i=0, const char *stringStack[]=0)
Definition: TTreeFormula.h:181
TTreeFormula::kTreeMember
@ kTreeMember
Definition: TTreeFormula.h:72
TTreeFormula::RealInstanceCache::fLocalIndexCache
Int_t fLocalIndexCache
Definition: TTreeFormula.h:91
TTreeFormula::kNeedEntries
@ kNeedEntries
Definition: TTreeFormula.h:67
TTreeFormula::fHasMultipleVarDim
UChar_t fHasMultipleVarDim[kMAXCODES]
Definition: TTreeFormula.h:115
TTreeFormula::GetLeafWithDatamember
TLeaf * GetLeafWithDatamember(const char *topchoice, const char *nextchice, Long64_t readentry) const
Return the leaf (if any) which contains an object containing a data member which has the name provide...
Definition: TTreeFormula.cxx:3060
TTreeFormula::fDataMembers
TObjArray fDataMembers
List of leaf used in this formula.
Definition: TTreeFormula.h:104
TString
Basic string class.
Definition: TString.h:136
TTreeFormula::kIteration
@ kIteration
Definition: TTreeFormula.h:71
Bool_t
bool Bool_t
Definition: RtypesCore.h:63
TTreeFormula::kMethod
@ kMethod
Definition: TTreeFormula.h:70
TTreeFormula::BranchHasMethod
Bool_t BranchHasMethod(TLeaf *leaf, TBranch *branch, const char *method, const char *params, Long64_t readentry) const
Return the leaf (if any) of the tree with contains an object of a class having a method which has the...
Definition: TTreeFormula.cxx:3226
TTreeFormula::kAlternateString
@ kAlternateString
Definition: TTreeFormula.h:82
TTreeFormula::StringToNumber
virtual Bool_t StringToNumber(Int_t code)
Try to 'demote' a string into an array bytes.
Definition: TTreeFormula.cxx:5037
bool
TTreeFormula::GetMethodCall
TMethodCall * GetMethodCall(Int_t code) const
Return methodcall corresponding to code.
Definition: TTreeFormula.cxx:4435
TTreeFormula::PrintValue
virtual char * PrintValue(Int_t mode=0) const
Return value of variable as a string.
Definition: TTreeFormula.cxx:4785
TTreeFormula::UpdateFormulaLeaves
virtual void UpdateFormulaLeaves()
This function is called TTreePlayer::UpdateFormulaLeaves, itself called by TChain::LoadTree when a ne...
Definition: TTreeFormula.cxx:5066
TTreeFormula::fNdimensions
Int_t fNdimensions[kMAXCODES]
If true, the current entry has not been loaded yet.
Definition: TTreeFormula.h:113
TBranch
A TTree is a list of TBranches.
Definition: TBranch.h:89
TTreeFormula::fAliases
TObjArray fAliases
List of TCutG and TEntryList used in the formula.
Definition: TTreeFormula.h:107
TTreeFormula::SetTree
virtual void SetTree(TTree *tree)
Definition: TTreeFormula.h:208
TTreeFormulaManager
Used to coordinate one or more TTreeFormula objects.
Definition: TTreeFormulaManager.h:30
TTreeFormula::fAliasesUsed
std::vector< std::string > fAliasesUsed
list of dimension setups, for delayed creation of the dimension information.
Definition: TTreeFormula.h:128
TTreeFormula::fHasCast
Bool_t fHasCast
Definition: TTreeFormula.h:99
TTreeFormula::GetNdata
virtual Int_t GetNdata()
Return number of available instances in the formula.
Definition: TTreeFormula.cxx:4444
TLeaf.h
TTreeFormula::kAliasString
@ kAliasString
Definition: TTreeFormula.h:80
TTreeFormula::GetLeaf
virtual TLeaf * GetLeaf(Int_t n) const
Return leaf corresponding to serial number n.
Definition: TTreeFormula.cxx:4424
TTreeFormula::Init
void Init(const char *name, const char *formula)
Initialiation called from the constructors.
Definition: TTreeFormula.cxx:178
TLeaf
A TLeaf describes individual elements of a TBranch See TBranch structure in TTree.
Definition: TLeaf.h:57
TTreeFormula::Notify
virtual Bool_t Notify()
This method must be overridden to handle object notification.
Definition: TTreeFormula.h:203
TTreeFormula::LoadCurrentDim
Bool_t LoadCurrentDim()
Calculate the actual dimension for the current entry.
Definition: TTreeFormula.cxx:5352
TTreeFormula::fLeafNames
TObjArray fLeafNames
List of TTreeFormula for each alias used.
Definition: TTreeFormula.h:108
TTreeFormula::EvalInstance
T EvalInstance(Int_t i=0, const char *stringStack[]=0)
Evaluate this treeformula.
Definition: TTreeFormula.cxx:3936
TTreeFormula::DefineAlternate
Int_t DefineAlternate(const char *expression)
This method check for treat the case where expression contains $Atl and load up both fAliases and fEx...
Definition: TTreeFormula.cxx:657
TTreeFormula::TTreeFormula
TTreeFormula(const TTreeFormula &)=delete
TLeafObject
A TLeaf for a general object derived from TObject.
Definition: TLeafObject.h:31
TTreeFormula::RegisterDimensions
Int_t RegisterDimensions(Int_t code, Int_t size, TFormLeafInfoMultiVarDim *multidim=0)
This method stores the dimension information for later usage.
Definition: TTreeFormula.cxx:439
TTreeFormula
Used to pass a selection expression to the Tree drawing routine.
Definition: TTreeFormula.h:58
TTreeFormula::kDirect
@ kDirect
Definition: TTreeFormula.h:70
TTreeFormula::GetNcodes
virtual Int_t GetNcodes() const
Definition: TTreeFormula.h:193
TTreeFormula::LoadBranches
void LoadBranches()
Make sure that all the branches have been loaded properly.
Definition: TTreeFormula.cxx:5328
BIT
#define BIT(n)
Definition: Rtypes.h:85
TTreeFormula::kLength
@ kLength
Definition: TTreeFormula.h:71
TTreeFormula::EvalClass
virtual TClass * EvalClass() const
Evaluate the class of this treeformula.
Definition: TTreeFormula.cxx:3580
TTreeFormula::fVarIndexes
TTreeFormula * fVarIndexes[kMAXCODES][kMAXFORMDIM]
Definition: TTreeFormula.h:120
kMAXCODES
const Int_t kMAXCODES
Definition: TTreeFormula.h:42
TTreeFormula::EvalStringInstance
virtual const char * EvalStringInstance(Int_t i=0)
Eval the instance as a string.
Definition: TTreeFormula.cxx:3693
TFormLeafInfo
This class is a small helper class to implement reading a data member on an object stored in a TTree.
Definition: TFormLeafInfo.h:49
TTreeFormula::kMaxIf
@ kMaxIf
Definition: TTreeFormula.h:84
TTreeFormula::fManager
TTreeFormulaManager * fManager
True if we executed one boolean optimization since the last time instance number 0 was evaluated.
Definition: TTreeFormula.h:124
TTreeFormula::GetValueFromMethod
virtual Double_t GetValueFromMethod(Int_t i, TLeaf *leaf) const
Return result of a leafobject method.
Definition: TTreeFormula.cxx:4452
TTreeFormula::kIndexOfEntry
@ kIndexOfEntry
Definition: TTreeFormula.h:71
unsigned int
TTreeFormula::GetMultiplicity
virtual Int_t GetMultiplicity() const
Definition: TTreeFormula.h:191
TTreeFormula::TTreeFormula
TTreeFormula()
Definition: TTreeFormula.cxx:124
TTreeFormula::kLocalEntries
@ kLocalEntries
Definition: TTreeFormula.h:75
RooFit_internal::instance
static Roo_reg_AGKInteg1D instance
Definition: RooAdaptiveGaussKronrodIntegrator1D.cxx:153
TTreeFormula::ParseWithLeaf
Int_t ParseWithLeaf(TLeaf *leaf, const char *expression, Bool_t final, UInt_t paran_level, TObjArray &castqueue, Bool_t useLeafCollectionObject, const char *fullExpression)
Decompose 'expression' as pointing to something inside the leaf Returns:
Definition: TTreeFormula.cxx:764
TFormLeafInfoMultiVarDim
A helper class to implement reading a data member on a variable size array inside a TClonesArray obje...
Definition: TFormLeafInfo.h:391
LongDouble_t
long double LongDouble_t
Definition: RtypesCore.h:61
TTreeFormula::fNcodes
Int_t fNcodes
This caches the physical number of element in the leaf or data member.
Definition: TTreeFormula.h:98
TTreeFormula::EvalInstanceLD
virtual LongDouble_t EvalInstanceLD(Int_t i=0, const char *stringStack[]=0)
Definition: TTreeFormula.h:183
Double_t
double Double_t
Definition: RtypesCore.h:59
ROOT::v5::TFormula
The FORMULA class (ROOT version 5)
Definition: TFormula.h:65
TTreeFormula::fNindex
Int_t fNindex
Definition: TTreeFormula.h:101
TTreeFormula::kMissingLeaf
@ kMissingLeaf
Definition: TTreeFormula.h:65
TTreeFormula::fNeedLoading
Bool_t fNeedLoading
If true, branch GetEntry is only called when the entry number changes.
Definition: TTreeFormula.h:111
TObjArray.h
TTreeFormula::fCumulSizes
Int_t fCumulSizes[kMAXCODES][kMAXFORMDIM]
Definition: TTreeFormula.h:118
TTreeFormula::fRealInstanceCache
RealInstanceCache fRealInstanceCache
local version of fConsts able to store bigger numbers
Definition: TTreeFormula.h:132
TClass
TClass instances represent classes, structs and namespaces in the ROOT type system.
Definition: TClass.h:80
UChar_t
unsigned char UChar_t
Definition: RtypesCore.h:38
kMAXFOUND
const Int_t kMAXFOUND
Definition: TFormula.h:31
TTreeFormula::FindLeafForExpression
Int_t FindLeafForExpression(const char *expression, TLeaf *&leaf, TString &leftover, Bool_t &final, UInt_t &paran_level, TObjArray &castqueue, std::vector< std::string > &aliasUsed, Bool_t &useLeafCollectionObject, const char *fullExpression)
Look for the leaf corresponding to the start of expression.
Definition: TTreeFormula.cxx:2174
TTreeFormula::IsString
virtual Bool_t IsString() const
Return TRUE if the formula is a string.
Definition: TTreeFormula.cxx:4685
ClassDef
#define ClassDef(name, id)
Definition: Rtypes.h:325
name
char name[80]
Definition: TGX11.cxx:110
ROOT::Math::Chebyshev::T
double T(double x)
Definition: ChebyshevPol.h:34
TTreeFormula::kSum
@ kSum
Definition: TTreeFormula.h:71
TTreeFormula::fConstLD
LongDouble_t * fConstLD
List of aliases used during the parsing of the expression.
Definition: TTreeFormula.h:130
TTreeFormula::kDataMember
@ kDataMember
Definition: TTreeFormula.h:70
TMethodCall
Method or function calling interface.
Definition: TMethodCall.h:37
TTreeFormula::fLeaves
TObjArray fLeaves
Definition: TTreeFormula.h:103
TTreeFormula::fAxis
TAxis * fAxis
Definition: TTreeFormula.h:122
TTreeFormula::GetRealInstance
Int_t GetRealInstance(Int_t instance, Int_t codeindex)
Now let calculate what physical instance we really need.
Definition: TTreeFormula.cxx:3345
TTreeFormula::IsLeafInteger
virtual Bool_t IsLeafInteger(Int_t code) const
Return TRUE if the leaf corresponding to code is short, int or unsigned short, int When a leaf is of ...
Definition: TTreeFormula.cxx:4637
TFormula.h
TTreeFormula::fDidBooleanOptimization
Bool_t fDidBooleanOptimization
pointer to histogram axis if this is a string
Definition: TTreeFormula.h:123
TTreeFormula::DefinedVariable
virtual Int_t DefinedVariable(TString &variable, Int_t &action)
Check if name is in the list of Tree/Branch leaves.
Definition: TTreeFormula.cxx:2684
TTreeFormula::fIndexes
Int_t fIndexes[kMAXCODES][kMAXFORMDIM]
Definition: TTreeFormula.h:119
TTreeFormula::GetValuePointerFromMethod
virtual void * GetValuePointerFromMethod(Int_t i, TLeaf *leaf) const
Return result of a leafobject method.
Definition: TTreeFormula.cxx:4513
TStreamerElement
Definition: TStreamerElement.h:33
TTreeFormula::IsQuickLoad
Bool_t IsQuickLoad() const
Definition: TTreeFormula.h:201
TTreeFormula::fTree
TTree * fTree
Definition: TTreeFormula.h:95
TObject::EStatusBits
EStatusBits
Definition: TObject.h:57
TTreeFormula::kEntries
@ kEntries
Definition: TTreeFormula.h:71
TTreeFormula::GetTree
virtual TTree * GetTree() const
Definition: TTreeFormula.h:210
TList
A doubly linked list.
Definition: TList.h:44
TTreeFormula::kAlias
@ kAlias
Definition: TTreeFormula.h:79
TArrayI
Array of integers (32 bits per element).
Definition: TArrayI.h:27
TTreeFormula::kLengthFunc
@ kLengthFunc
Definition: TTreeFormula.h:71
int
TTreeFormula::~TTreeFormula
virtual ~TTreeFormula()
Tree Formula default destructor.
Definition: TTreeFormula.cxx:324
kMAXFORMDIM
const Int_t kMAXFORMDIM
Definition: TTreeFormula.h:43