Logo ROOT   6.16/01
Reference Guide
TTree.h
Go to the documentation of this file.
1// @(#)root/tree:$Id$
2// Author: Rene Brun 12/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
12#ifndef ROOT_TTree
13#define ROOT_TTree
14
15//////////////////////////////////////////////////////////////////////////
16// //
17// TTree //
18// //
19// A TTree object is a list of TBranch. //
20// To Create a TTree object one must: //
21// - Create the TTree header via the TTree constructor //
22// - Call the TBranch constructor for every branch. //
23// //
24// To Fill this object, use member function Fill with no parameters. //
25// The Fill function loops on all defined TBranch. //
26// //
27//////////////////////////////////////////////////////////////////////////
28
29#include "Compression.h"
30#include "ROOT/TIOFeatures.hxx"
31#include "TArrayD.h"
32#include "TArrayI.h"
33#include "TAttFill.h"
34#include "TAttLine.h"
35#include "TAttMarker.h"
36#include "TBranch.h"
37#include "TBuffer.h"
38#include "TClass.h"
39#include "TDataType.h"
40#include "TDirectory.h"
41#include "TObjArray.h"
42#include "TVirtualTreePlayer.h"
43
44#include <atomic>
45
46
47class TBranch;
48class TBrowser;
49class TFile;
50class TLeaf;
51class TH1;
52class TTreeFormula;
53class TPolyMarker;
54class TEventList;
55class TEntryList;
56class TList;
57class TSQLResult;
58class TSelector;
59class TPrincipal;
60class TFriendElement;
61class TCut;
62class TVirtualIndex;
63class TBranchRef;
64class TBasket;
65class TStreamerInfo;
66class TTreeCache;
67class TTreeCloner;
68class TFileMergeInfo;
70
71class TTree : public TNamed, public TAttLine, public TAttFill, public TAttMarker {
72
74
75protected:
76 Long64_t fEntries; ///< Number of entries
77// NOTE: cannot use std::atomic for these counters as it cannot be serialized.
78 Long64_t fTotBytes; ///< Total number of bytes in all branches before compression
79 Long64_t fZipBytes; ///< Total number of bytes in all branches after compression
80 Long64_t fSavedBytes; ///< Number of autosaved bytes
81 Long64_t fFlushedBytes; ///< Number of auto-flushed bytes
82 Double_t fWeight; ///< Tree weight (see TTree::SetWeight)
83 Int_t fTimerInterval; ///< Timer interval in milliseconds
84 Int_t fScanField; ///< Number of runs before prompting in Scan
85 Int_t fUpdate; ///< Update frequency for EntryLoop
86 Int_t fDefaultEntryOffsetLen; ///< Initial Length of fEntryOffset table in the basket buffers
87 Int_t fNClusterRange; ///< Number of Cluster range in addition to the one defined by 'AutoFlush'
88 Int_t fMaxClusterRange; ///<! Memory allocated for the cluster range.
89 Long64_t fMaxEntries; ///< Maximum number of entries in case of circular buffers
90 Long64_t fMaxEntryLoop; ///< Maximum number of entries to process
91 Long64_t fMaxVirtualSize; ///< Maximum total size of buffers kept in memory
92 Long64_t fAutoSave; ///< Autosave tree when fAutoSave entries written or -fAutoSave (compressed) bytes produced
93 Long64_t fAutoFlush; ///< Auto-flush tree when fAutoFlush entries written or -fAutoFlush (compressed) bytes produced
94 Long64_t fEstimate; ///< Number of entries to estimate histogram limits
95 Long64_t *fClusterRangeEnd; ///<[fNClusterRange] Last entry of a cluster range.
96 Long64_t *fClusterSize; ///<[fNClusterRange] Number of entries in each cluster for a given range.
97 Long64_t fCacheSize; ///<! Maximum size of file buffers
98 Long64_t fChainOffset; ///<! Offset of 1st entry of this Tree in a TChain
99 Long64_t fReadEntry; ///<! Number of the entry being processed
100 std::atomic<Long64_t> fTotalBuffers; ///<! Total number of bytes in branch buffers
101 Int_t fPacketSize; ///<! Number of entries in one packet for parallel root
102 Int_t fNfill; ///<! Local for EntryLoop
103 Int_t fDebug; ///<! Debug level
104 Long64_t fDebugMin; ///<! First entry number to debug
105 Long64_t fDebugMax; ///<! Last entry number to debug
106 TIOFeatures fIOFeatures{0}; ///< IO features to define for newly-written baskets and branches.
107 Int_t fMakeClass; ///<! not zero when processing code generated by MakeClass
108 Int_t fFileNumber; ///<! current file number (if file extensions)
109 TObject *fNotify; ///<! Object to be notified when loading a Tree
110 TDirectory *fDirectory; ///<! Pointer to directory holding this tree
111 TObjArray fBranches; ///< List of Branches
112 TObjArray fLeaves; ///< Direct pointers to individual branch leaves
113 TList *fAliases; ///< List of aliases for expressions based on the tree branches.
114 TEventList *fEventList; ///<! Pointer to event selection list (if one)
115 TEntryList *fEntryList; ///<! Pointer to event selection list (if one)
116 TArrayD fIndexValues; ///< Sorted index values
117 TArrayI fIndex; ///< Index of sorted values
118 TVirtualIndex *fTreeIndex; ///< Pointer to the tree Index (if any)
119 TList *fFriends; ///< pointer to list of friend elements
120 TVirtualPerfStats *fPerfStats; ///<! pointer to the current perf stats object
121 TList *fUserInfo; ///< pointer to a list of user objects associated to this Tree
122 TVirtualTreePlayer *fPlayer; ///<! Pointer to current Tree player
123 TList *fClones; ///<! List of cloned trees which share our addresses
124 TBranchRef *fBranchRef; ///< Branch supporting the TRefTable (if any)
125 UInt_t fFriendLockStatus; ///<! Record which method is locking the friend recursion
126 TBuffer *fTransientBuffer; ///<! Pointer to the current transient buffer.
127 Bool_t fCacheDoAutoInit; ///<! true if cache auto creation or resize check is needed
128 Bool_t fCacheDoClusterPrefetch;///<! true if cache is prefetching whole clusters
129 Bool_t fCacheUserSet; ///<! true if the cache setting was explicitly given by user
130 Bool_t fIMTEnabled; ///<! true if implicit multi-threading is enabled for this tree
131 UInt_t fNEntriesSinceSorting; ///<! Number of entries processed since the last re-sorting of branches
132 std::vector<std::pair<Long64_t,TBranch*>> fSortedBranches; ///<! Branches to be processed in parallel when IMT is on, sorted by average task time
133 std::vector<TBranch*> fSeqBranches; ///<! Branches to be processed sequentially when IMT is on
134 Float_t fTargetMemoryRatio{1.1f}; ///<! Ratio for memory usage in uncompressed buffers versus actual occupancy. 1.0
135 /// indicates basket should be resized to exact memory usage, but causes significant
136/// memory churn.
137#ifdef R__TRACK_BASKET_ALLOC_TIME
138 mutable std::atomic<ULong64_t> fAllocationTime{0}; ///<! Time spent reallocating basket memory buffers, in microseconds.
139#endif
140 mutable std::atomic<UInt_t> fAllocationCount{0}; ///<! Number of reallocations basket memory buffers.
141
142 static Int_t fgBranchStyle; ///< Old/New branch style
143 static Long64_t fgMaxTreeSize; ///< Maximum size of a file containing a Tree
144
145private:
146 // For simplicity, although fIMTFlush is always disabled in non-IMT builds, we don't #ifdef it out.
147 mutable Bool_t fIMTFlush{false}; ///<! True if we are doing a multithreaded flush.
148 mutable std::atomic<Long64_t> fIMTTotBytes; ///<! Total bytes for the IMT flush baskets
149 mutable std::atomic<Long64_t> fIMTZipBytes; ///<! Zip bytes for the IMT flush baskets.
150
151 void InitializeBranchLists(bool checkLeafCount);
152 void SortBranchesByTime();
153 Int_t FlushBasketsImpl() const;
154 void MarkEventCluster();
155
156protected:
157 virtual void KeepCircular();
158 virtual TBranch *BranchImp(const char* branchname, const char* classname, TClass* ptrClass, void* addobj, Int_t bufsize, Int_t splitlevel);
159 virtual TBranch *BranchImp(const char* branchname, TClass* ptrClass, void* addobj, Int_t bufsize, Int_t splitlevel);
160 virtual TBranch *BranchImpRef(const char* branchname, const char* classname, TClass* ptrClass, void* addobj, Int_t bufsize, Int_t splitlevel);
161 virtual TBranch *BranchImpRef(const char* branchname, TClass* ptrClass, EDataType datatype, void* addobj, Int_t bufsize, Int_t splitlevel);
162 virtual Int_t CheckBranchAddressType(TBranch* branch, TClass* ptrClass, EDataType datatype, Bool_t ptr);
163 virtual TBranch *BronchExec(const char* name, const char* classname, void* addobj, Bool_t isptrptr, Int_t bufsize, Int_t splitlevel);
164 friend TBranch *TTreeBranchImpRef(TTree *tree, const char* branchname, TClass* ptrClass, EDataType datatype, void* addobj, Int_t bufsize, Int_t splitlevel);
165 Int_t SetBranchAddressImp(TBranch *branch, void* addr, TBranch** ptr);
166 virtual TLeaf *GetLeafImpl(const char* branchname, const char* leafname);
167
168 Long64_t GetCacheAutoSize(Bool_t withDefault = kFALSE) const;
169 char GetNewlineValue(std::istream &inputStream);
170 void ImportClusterRanges(TTree *fromtree);
171 void MoveReadCache(TFile *src, TDirectory *dir);
172 Int_t SetCacheSizeAux(Bool_t autocache = kTRUE, Long64_t cacheSize = 0);
173
175 // Helper class to prevent infinite recursion in the
176 // usage of TTree Friends. Implemented in TTree.cxx.
177 TTree *fTree; // Pointer to the locked tree
178 UInt_t fMethodBit; // BIT for the locked method
179 Bool_t fPrevious; // Previous value of the BIT.
180
181 protected:
182 TFriendLock(const TFriendLock&);
184
185 public:
186 TFriendLock(TTree* tree, UInt_t methodbit);
187 ~TFriendLock();
188 };
189 friend class TFriendLock;
190 // So that the index class can use TFriendLock:
191 friend class TTreeIndex;
192 friend class TChainIndex;
193 // So that the TTreeCloner can access the protected interfaces
194 friend class TTreeCloner;
195
196 // use to update fFriendLockStatus
208 kPrint = BIT(10),
211 };
212
213public:
214 // Used as the max value for any TTree range operation.
216
217 // SetBranchAddress return values
229 kNoCheck = 5
230 };
231
232 // TTree status bits
236 kOnlyFlushAtCluster = BIT(14) // If set, the branch's buffers will grow until an event cluster boundary is hit,
237 // guaranteeing a basket per cluster. This mode does not provide any guarantee on the
238 // memory bounds in the case of extremely large events.
239 };
240
241 // Split level modifier
242 enum {
244 };
245
247 {
248 private:
249 TTree *fTree; // TTree upon which we are iterating.
250 Int_t fClusterRange; // Which cluster range are we looking at.
251 Long64_t fStartEntry; // Where does the cluster start.
252 Long64_t fNextEntry; // Where does the cluster end (exclusive).
253 Long64_t fEstimatedSize; // If positive, the calculated estimated tree size.
254
256
257 protected:
258 friend class TTree;
259 TClusterIterator(TTree *tree, Long64_t firstEntry);
260
261 public:
262 // Intentionally used the default copy constructor and default destructor
263 // as the TClusterIterator does not own the TTree.
264 // TClusterIterator(const TClusterIterator&);
265 // ~TClusterIterator();
266
267 // No public constructors, the iterator must be
268 // created via TTree::GetClusterIterator
269
270 // Move on to the next cluster and return the starting entry
271 // of this next cluster
272 Long64_t Next();
273
274 // Move on to the previous cluster and return the starting entry
275 // of this previous cluster
277
278 // Return the start entry of the current cluster.
280 return fStartEntry;
281 }
282
283 // Return the first entry of the next cluster.
285 return fNextEntry;
286 }
287
288 Long64_t operator()() { return Next(); }
289 };
290
291 TTree();
292 TTree(const char* name, const char* title, Int_t splitlevel = 99, TDirectory* dir = gDirectory);
293 virtual ~TTree();
294
295 TTree(const TTree& tt) = delete;
296 TTree& operator=(const TTree& tt) = delete;
297
298 virtual Int_t AddBranchToCache(const char *bname, Bool_t subbranches = kFALSE);
299 virtual Int_t AddBranchToCache(TBranch *branch, Bool_t subbranches = kFALSE);
300 virtual Int_t DropBranchFromCache(const char *bname, Bool_t subbranches = kFALSE);
301 virtual Int_t DropBranchFromCache(TBranch *branch, Bool_t subbranches = kFALSE);
302 void AddClone(TTree*);
303 virtual TFriendElement *AddFriend(const char* treename, const char* filename = "");
304 virtual TFriendElement *AddFriend(const char* treename, TFile* file);
305 virtual TFriendElement *AddFriend(TTree* tree, const char* alias = "", Bool_t warn = kFALSE);
306 // As the TBasket invokes Add{Tot,Zip}Bytes on its parent tree, we must do these updates in a thread-safe
307 // manner only when we are flushing multiple baskets in parallel.
308 virtual void AddTotBytes(Int_t tot) { if (fIMTFlush) { fIMTTotBytes += tot; } else { fTotBytes += tot; } }
309 virtual void AddZipBytes(Int_t zip) { if (fIMTFlush) { fIMTZipBytes += zip; } else { fZipBytes += zip; } }
310// NOTE: these counters aren't thread safe like the ones above.
311#ifdef R__TRACK_BASKET_ALLOC_TIME
312 void AddAllocationTime(ULong64_t time) { fAllocationTime += time; }
313#endif
315 virtual Long64_t AutoSave(Option_t* option = "");
316 virtual Int_t Branch(TCollection* list, Int_t bufsize = 32000, Int_t splitlevel = 99, const char* name = "");
317 virtual Int_t Branch(TList* list, Int_t bufsize = 32000, Int_t splitlevel = 99);
318 virtual Int_t Branch(const char* folder, Int_t bufsize = 32000, Int_t splitlevel = 99);
319 virtual TBranch *Branch(const char* name, void* address, const char* leaflist, Int_t bufsize = 32000);
320 TBranch *Branch(const char* name, char* address, const char* leaflist, Int_t bufsize = 32000)
321 {
322 // Overload to avoid confusion between this signature and the template instance.
323 return Branch(name,(void*)address,leaflist,bufsize);
324 }
325 TBranch *Branch(const char* name, Long_t address, const char* leaflist, Int_t bufsize = 32000)
326 {
327 // Overload to avoid confusion between this signature and the template instance.
328 return Branch(name,(void*)address,leaflist,bufsize);
329 }
330 TBranch *Branch(const char* name, int address, const char* leaflist, Int_t bufsize = 32000)
331 {
332 // Overload to avoid confusion between this signature and the template instance.
333 return Branch(name,(void*)(Long_t)address,leaflist,bufsize);
334 }
335 virtual TBranch *Branch(const char* name, const char* classname, void* addobj, Int_t bufsize = 32000, Int_t splitlevel = 99);
336 template <class T> TBranch *Branch(const char* name, const char* classname, T* obj, Int_t bufsize = 32000, Int_t splitlevel = 99)
337 {
338 // See BranchImpRed for details. Here we __ignore
339 return BranchImpRef(name, classname, TBuffer::GetClass(typeid(T)), obj, bufsize, splitlevel);
340 }
341 template <class T> TBranch *Branch(const char* name, const char* classname, T** addobj, Int_t bufsize = 32000, Int_t splitlevel = 99)
342 {
343 // See BranchImp for details
344 return BranchImp(name, classname, TBuffer::GetClass(typeid(T)), addobj, bufsize, splitlevel);
345 }
346 template <class T> TBranch *Branch(const char* name, T** addobj, Int_t bufsize = 32000, Int_t splitlevel = 99)
347 {
348 // See BranchImp for details
349 return BranchImp(name, TBuffer::GetClass(typeid(T)), addobj, bufsize, splitlevel);
350 }
351 template <class T> TBranch *Branch(const char* name, T* obj, Int_t bufsize = 32000, Int_t splitlevel = 99)
352 {
353 // See BranchImp for details
354 return BranchImpRef(name, TBuffer::GetClass(typeid(T)), TDataType::GetType(typeid(T)), obj, bufsize, splitlevel);
355 }
356 virtual TBranch *Bronch(const char* name, const char* classname, void* addobj, Int_t bufsize = 32000, Int_t splitlevel = 99);
357 virtual TBranch *BranchOld(const char* name, const char* classname, void* addobj, Int_t bufsize = 32000, Int_t splitlevel = 1);
358 virtual TBranch *BranchRef();
359 virtual void Browse(TBrowser*);
360 virtual Int_t BuildIndex(const char* majorname, const char* minorname = "0");
361 TStreamerInfo *BuildStreamerInfo(TClass* cl, void* pointer = 0, Bool_t canOptimize = kTRUE);
362 virtual TFile *ChangeFile(TFile* file);
363 virtual TTree *CloneTree(Long64_t nentries = -1, Option_t* option = "");
364 virtual void CopyAddresses(TTree*,Bool_t undo = kFALSE);
365 virtual Long64_t CopyEntries(TTree* tree, Long64_t nentries = -1, Option_t *option = "");
366 virtual TTree *CopyTree(const char* selection, Option_t* option = "", Long64_t nentries = kMaxEntries, Long64_t firstentry = 0);
367 virtual TBasket *CreateBasket(TBranch*);
368 virtual void DirectoryAutoAdd(TDirectory *);
369 Int_t Debug() const { return fDebug; }
370 virtual void Delete(Option_t* option = ""); // *MENU*
371 virtual void Draw(Option_t* opt) { Draw(opt, "", "", kMaxEntries, 0); }
372 virtual Long64_t Draw(const char* varexp, const TCut& selection, Option_t* option = "", Long64_t nentries = kMaxEntries, Long64_t firstentry = 0);
373 virtual Long64_t Draw(const char* varexp, const char* selection, Option_t* option = "", Long64_t nentries = kMaxEntries, Long64_t firstentry = 0); // *MENU*
374 virtual void DropBaskets();
375 virtual void DropBuffers(Int_t nbytes);
376 virtual Int_t Fill();
377 virtual TBranch *FindBranch(const char* name);
378 virtual TLeaf *FindLeaf(const char* name);
379 virtual Int_t Fit(const char* funcname, const char* varexp, const char* selection = "", Option_t* option = "", Option_t* goption = "", Long64_t nentries = kMaxEntries, Long64_t firstentry = 0); // *MENU*
380 virtual Int_t FlushBaskets(Bool_t create_cluster = true) const;
381 virtual const char *GetAlias(const char* aliasName) const;
383#ifdef R__TRACK_BASKET_ALLOC_TIME
384 ULong64_t GetAllocationTime() const { return fAllocationTime; }
385#endif
386 virtual Long64_t GetAutoFlush() const {return fAutoFlush;}
387 virtual Long64_t GetAutoSave() const {return fAutoSave;}
388 virtual TBranch *GetBranch(const char* name);
389 virtual TBranchRef *GetBranchRef() const { return fBranchRef; };
390 virtual Bool_t GetBranchStatus(const char* branchname) const;
391 static Int_t GetBranchStyle();
392 virtual Long64_t GetCacheSize() const { return fCacheSize; }
393 virtual TClusterIterator GetClusterIterator(Long64_t firstentry);
394 virtual Long64_t GetChainEntryNumber(Long64_t entry) const { return entry; }
395 virtual Long64_t GetChainOffset() const { return fChainOffset; }
397 TFile *GetCurrentFile() const;
399 Long64_t GetDebugMax() const { return fDebugMax; }
400 Long64_t GetDebugMin() const { return fDebugMin; }
401 TDirectory *GetDirectory() const { return fDirectory; }
402 virtual Long64_t GetEntries() const { return fEntries; }
403 virtual Long64_t GetEntries(const char *selection);
404 virtual Long64_t GetEntriesFast() const { return fEntries; }
405 virtual Long64_t GetEntriesFriend() const;
406 virtual Long64_t GetEstimate() const { return fEstimate; }
407 virtual Int_t GetEntry(Long64_t entry = 0, Int_t getall = 0);
408 Int_t GetEvent(Long64_t entry = 0, Int_t getall = 0) { return GetEntry(entry, getall); }
409 virtual Int_t GetEntryWithIndex(Int_t major, Int_t minor = 0);
410 virtual Long64_t GetEntryNumberWithBestIndex(Long64_t major, Long64_t minor = 0) const;
411 virtual Long64_t GetEntryNumberWithIndex(Long64_t major, Long64_t minor = 0) const;
412 TEventList *GetEventList() const { return fEventList; }
413 virtual TEntryList *GetEntryList();
414 virtual Long64_t GetEntryNumber(Long64_t entry) const;
415 virtual Int_t GetFileNumber() const { return fFileNumber; }
416 virtual TTree *GetFriend(const char*) const;
417 virtual const char *GetFriendAlias(TTree*) const;
419 virtual Bool_t GetImplicitMT() { return fIMTEnabled; }
420 virtual Int_t *GetIndex() { return &fIndex.fArray[0]; }
421 virtual Double_t *GetIndexValues() { return &fIndexValues.fArray[0]; }
424 virtual TLeaf *GetLeaf(const char* branchname, const char* leafname);
425 virtual TLeaf *GetLeaf(const char* name);
426 virtual TList *GetListOfClones() { return fClones; }
427 virtual TObjArray *GetListOfBranches() { return &fBranches; }
428 virtual TObjArray *GetListOfLeaves() { return &fLeaves; }
429 virtual TList *GetListOfFriends() const { return fFriends; }
430 virtual TList *GetListOfAliases() const { return fAliases; }
431
432 // GetMakeClass is left non-virtual for efficiency reason.
433 // Making it virtual affects the performance of the I/O
434 Int_t GetMakeClass() const { return fMakeClass; }
435
436 virtual Long64_t GetMaxEntryLoop() const { return fMaxEntryLoop; }
437 virtual Double_t GetMaximum(const char* columname);
438 static Long64_t GetMaxTreeSize();
439 virtual Long64_t GetMaxVirtualSize() const { return fMaxVirtualSize; }
440 virtual Double_t GetMinimum(const char* columname);
442 TObject *GetNotify() const { return fNotify; }
444 virtual Int_t GetPacketSize() const { return fPacketSize; }
445 virtual TVirtualPerfStats *GetPerfStats() const { return fPerfStats; }
448 virtual Long64_t GetReadEntry() const { return fReadEntry; }
449 virtual Long64_t GetReadEvent() const { return fReadEntry; }
450 virtual Int_t GetScanField() const { return fScanField; }
453 virtual Int_t GetTimerInterval() const { return fTimerInterval; }
455 virtual Long64_t GetTotBytes() const { return fTotBytes; }
456 virtual TTree *GetTree() const { return const_cast<TTree*>(this); }
457 virtual TVirtualIndex *GetTreeIndex() const { return fTreeIndex; }
458 virtual Int_t GetTreeNumber() const { return 0; }
460 virtual Int_t GetUpdate() const { return fUpdate; }
461 virtual TList *GetUserInfo();
462 // See TSelectorDraw::GetVar
464 // See TSelectorDraw::GetVar
466 // See TSelectorDraw::GetVar
468 // See TSelectorDraw::GetVar
470 // See TSelectorDraw::GetVar
472 // See TSelectorDraw::GetVal
473 virtual Double_t *GetVal(Int_t i) { return GetPlayer()->GetVal(i); }
474 // See TSelectorDraw::GetVal
475 virtual Double_t *GetV1() { return GetPlayer()->GetV1(); }
476 // See TSelectorDraw::GetVal
477 virtual Double_t *GetV2() { return GetPlayer()->GetV2(); }
478 // See TSelectorDraw::GetVal
479 virtual Double_t *GetV3() { return GetPlayer()->GetV3(); }
480 // See TSelectorDraw::GetVal
481 virtual Double_t *GetV4() { return GetPlayer()->GetV4(); }
482 virtual Double_t *GetW() { return GetPlayer()->GetW(); }
483 virtual Double_t GetWeight() const { return fWeight; }
484 virtual Long64_t GetZipBytes() const { return fZipBytes; }
485 virtual void IncrementTotalBuffers(Int_t nbytes) { fTotalBuffers += nbytes; }
486 Bool_t IsFolder() const { return kTRUE; }
487 virtual Int_t LoadBaskets(Long64_t maxmemory = 2000000000);
488 virtual Long64_t LoadTree(Long64_t entry);
489 virtual Long64_t LoadTreeFriend(Long64_t entry, TTree* T);
490 virtual Int_t MakeClass(const char* classname = 0, Option_t* option = "");
491 virtual Int_t MakeCode(const char* filename = 0);
492 virtual Int_t MakeProxy(const char* classname, const char* macrofilename = 0, const char* cutfilename = 0, const char* option = 0, Int_t maxUnrolling = 3);
493 virtual Int_t MakeSelector(const char* selector = 0, Option_t* option = "");
494 Bool_t MemoryFull(Int_t nbytes);
495 virtual Long64_t Merge(TCollection* list, Option_t* option = "");
496 virtual Long64_t Merge(TCollection* list, TFileMergeInfo *info);
497 static TTree *MergeTrees(TList* list, Option_t* option = "");
498 virtual Bool_t Notify();
499 virtual void OptimizeBaskets(ULong64_t maxMemory=10000000, Float_t minComp=1.1, Option_t *option="");
500 TPrincipal *Principal(const char* varexp = "", const char* selection = "", Option_t* option = "np", Long64_t nentries = kMaxEntries, Long64_t firstentry = 0);
501 virtual void Print(Option_t* option = "") const; // *MENU*
502 virtual void PrintCacheStats(Option_t* option = "") const;
503 virtual Long64_t Process(const char* filename, Option_t* option = "", Long64_t nentries = kMaxEntries, Long64_t firstentry = 0); // *MENU*
504 virtual Long64_t Process(TSelector* selector, Option_t* option = "", Long64_t nentries = kMaxEntries, Long64_t firstentry = 0);
505 virtual Long64_t Project(const char* hname, const char* varexp, const char* selection = "", Option_t* option = "", Long64_t nentries = kMaxEntries, Long64_t firstentry = 0);
506 virtual TSQLResult *Query(const char* varexp = "", const char* selection = "", Option_t* option = "", Long64_t nentries = kMaxEntries, Long64_t firstentry = 0);
507 virtual Long64_t ReadFile(const char* filename, const char* branchDescriptor = "", char delimiter = ' ');
508 virtual Long64_t ReadStream(std::istream& inputStream, const char* branchDescriptor = "", char delimiter = ' ');
509 virtual void Refresh();
510 virtual void RecursiveRemove(TObject *obj);
511 virtual void RemoveFriend(TTree*);
512 virtual void Reset(Option_t* option = "");
513 virtual void ResetAfterMerge(TFileMergeInfo *);
514 virtual void ResetBranchAddress(TBranch *);
515 virtual void ResetBranchAddresses();
516 virtual Long64_t Scan(const char* varexp = "", const char* selection = "", Option_t* option = "", Long64_t nentries = kMaxEntries, Long64_t firstentry = 0); // *MENU*
517 virtual Bool_t SetAlias(const char* aliasName, const char* aliasFormula);
518 virtual void SetAutoSave(Long64_t autos = -300000000);
519 virtual void SetAutoFlush(Long64_t autof = -30000000);
520 virtual void SetBasketSize(const char* bname, Int_t buffsize = 16000);
521 virtual Int_t SetBranchAddress(const char *bname,void *add, TBranch **ptr = 0);
522 virtual Int_t SetBranchAddress(const char *bname,void *add, TClass *realClass, EDataType datatype, Bool_t isptr);
523 virtual Int_t SetBranchAddress(const char *bname,void *add, TBranch **ptr, TClass *realClass, EDataType datatype, Bool_t isptr);
524 template <class T> Int_t SetBranchAddress(const char *bname, T **add, TBranch **ptr = 0) {
525 TClass *cl = TClass::GetClass(typeid(T));
527 if (cl==0) type = TDataType::GetType(typeid(T));
528 return SetBranchAddress(bname,add,ptr,cl,type,true);
529 }
530#ifndef R__NO_CLASS_TEMPLATE_SPECIALIZATION
531 // This can only be used when the template overload resolution can distinguish between
532 // T* and T**
533 template <class T> Int_t SetBranchAddress(const char *bname, T *add, TBranch **ptr = 0) {
534 TClass *cl = TClass::GetClass(typeid(T));
536 if (cl==0) type = TDataType::GetType(typeid(T));
537 return SetBranchAddress(bname,add,ptr,cl,type,false);
538 }
539#endif
540 virtual void SetBranchStatus(const char* bname, Bool_t status = 1, UInt_t* found = 0);
541 static void SetBranchStyle(Int_t style = 1); //style=0 for old branch, =1 for new branch style
542 virtual Int_t SetCacheSize(Long64_t cachesize = -1);
544 virtual void SetCacheLearnEntries(Int_t n=10);
545 virtual void SetChainOffset(Long64_t offset = 0) { fChainOffset=offset; }
546 virtual void SetCircular(Long64_t maxEntries);
547 virtual void SetClusterPrefetch(Bool_t enabled) { fCacheDoClusterPrefetch = enabled; }
548 virtual void SetDebug(Int_t level = 1, Long64_t min = 0, Long64_t max = 9999999); // *MENU*
549 virtual void SetDefaultEntryOffsetLen(Int_t newdefault, Bool_t updateExisting = kFALSE);
550 virtual void SetDirectory(TDirectory* dir);
551 virtual Long64_t SetEntries(Long64_t n = -1);
552 virtual void SetEstimate(Long64_t nentries = 1000000);
554 virtual void SetFileNumber(Int_t number = 0);
555 virtual void SetEventList(TEventList* list);
556 virtual void SetEntryList(TEntryList* list, Option_t *opt="");
557 virtual void SetImplicitMT(Bool_t enabled) { fIMTEnabled = enabled; }
558 virtual void SetMakeClass(Int_t make);
559 virtual void SetMaxEntryLoop(Long64_t maxev = kMaxEntries) { fMaxEntryLoop = maxev; } // *MENU*
560 static void SetMaxTreeSize(Long64_t maxsize = 100000000000LL);
561 virtual void SetMaxVirtualSize(Long64_t size = 0) { fMaxVirtualSize = size; } // *MENU*
562 virtual void SetName(const char* name); // *MENU*
563
564 /**
565 * @brief Sets the address of the object to be notified when the tree is loaded.
566 *
567 * The method TObject::Notify is called for the given object when the tree
568 * is loaded. Specifically this occurs in the TTree::LoadTree method. To
569 * remove the notification call this method with nullptr:
570 * @code tree->SetNotify(nullptr); @endcode
571 *
572 * @param[in] obj Pointer to a TObject to be notified.
573 */
574 virtual void SetNotify(TObject* obj) { fNotify = obj; }
575
576 virtual void SetObject(const char* name, const char* title);
577 virtual void SetParallelUnzip(Bool_t opt=kTRUE, Float_t RelSize=-1);
578 virtual void SetPerfStats(TVirtualPerfStats* perf);
579 virtual void SetScanField(Int_t n = 50) { fScanField = n; } // *MENU*
581 virtual void SetTimerInterval(Int_t msec = 333) { fTimerInterval=msec; }
582 virtual void SetTreeIndex(TVirtualIndex* index);
583 virtual void SetWeight(Double_t w = 1, Option_t* option = "");
584 virtual void SetUpdate(Int_t freq = 0) { fUpdate = freq; }
585 virtual void Show(Long64_t entry = -1, Int_t lenmax = 20);
586 virtual void StartViewer(); // *MENU*
588 virtual Int_t UnbinnedFit(const char* funcname, const char* varexp, const char* selection = "", Option_t* option = "", Long64_t nentries = kMaxEntries, Long64_t firstentry = 0);
589 void UseCurrentStyle();
590 virtual Int_t Write(const char *name=0, Int_t option=0, Int_t bufsize=0);
591 virtual Int_t Write(const char *name=0, Int_t option=0, Int_t bufsize=0) const;
592
593 ClassDef(TTree, 20) // Tree descriptor (the main ROOT I/O class)
594};
595
596//////////////////////////////////////////////////////////////////////////
597// //
598// TTreeFriendLeafIter //
599// //
600// Iterator on all the leaves in a TTree and its friend //
601// //
602//////////////////////////////////////////////////////////////////////////
603
605
606protected:
607 TTree *fTree; ///< tree being iterated
608 TIterator *fLeafIter; ///< current leaf sub-iterator.
609 TIterator *fTreeIter; ///< current tree sub-iterator.
610 Bool_t fDirection; ///< iteration direction
611
613 fDirection(0) { }
614
615public:
619 TIterator &operator=(const TIterator &rhs);
621
622 const TCollection *GetCollection() const { return 0; }
623 Option_t *GetOption() const;
624 TObject *Next();
627 // TODO: Implement me
628 return false;
629 }
631 // TODO: Implement me
632 return false;
633 }
635 // TODO: Implement me
636 return nullptr;
637 }
638 ClassDef(TTreeFriendLeafIter,0) //Linked list iterator
639 };
640
641
642#endif
#define SafeDelete(p)
Definition: RConfig.hxx:529
int Int_t
Definition: RtypesCore.h:41
unsigned int UInt_t
Definition: RtypesCore.h:42
const Bool_t kFALSE
Definition: RtypesCore.h:88
long Long_t
Definition: RtypesCore.h:50
bool Bool_t
Definition: RtypesCore.h:59
double Double_t
Definition: RtypesCore.h:55
long long Long64_t
Definition: RtypesCore.h:69
unsigned long long ULong64_t
Definition: RtypesCore.h:70
float Float_t
Definition: RtypesCore.h:53
const Bool_t kTRUE
Definition: RtypesCore.h:87
const char Option_t
Definition: RtypesCore.h:62
#define ClassDef(name, id)
Definition: Rtypes.h:324
#define BIT(n)
Definition: Rtypes.h:82
const Bool_t kIterForward
Definition: TCollection.h:40
EDataType
Definition: TDataType.h:28
@ kOther_t
Definition: TDataType.h:32
#define gDirectory
Definition: TDirectory.h:213
int type
Definition: TGX11.cxx:120
int nentries
Definition: THbookFile.cxx:89
TIOFeatures provides the end-user with the ability to change the IO behavior of data written via a TT...
Definition: TIOFeatures.hxx:62
Array of doubles (64 bits per element).
Definition: TArrayD.h:27
Double_t * fArray
Definition: TArrayD.h:30
Array of integers (32 bits per element).
Definition: TArrayI.h:27
Int_t * fArray
Definition: TArrayI.h:30
Fill Area Attributes class.
Definition: TAttFill.h:19
Line Attributes class.
Definition: TAttLine.h:18
Marker Attributes class.
Definition: TAttMarker.h:19
Manages buffers for branches of a Tree.
Definition: TBasket.h:34
A branch containing and managing a TRefTable for TRef autoloading.
Definition: TBranchRef.h:29
A TTree is a list of TBranches.
Definition: TBranch.h:64
Using a TBrowser one can browse all ROOT objects.
Definition: TBrowser.h:37
Buffer base class used for serializing objects.
Definition: TBuffer.h:40
static TClass * GetClass(const std::type_info &typeinfo)
Forward to TROOT::GetClass().
Definition: TBuffer.cxx:307
A Chain Index.
Definition: TChainIndex.h:39
The ROOT global object gROOT contains a list of all defined classes.
Definition: TClass.h:75
static TClass * GetClass(const char *name, Bool_t load=kTRUE, Bool_t silent=kFALSE)
Static method returning pointer to TClass of the specified class name.
Definition: TClass.cxx:2885
Collection abstract base class.
Definition: TCollection.h:63
A specialized string object used for TTree selections.
Definition: TCut.h:25
Int_t GetType() const
Definition: TDataType.h:68
Describe directory structure in memory.
Definition: TDirectory.h:34
A List of entry numbers in a TTree or TChain.
Definition: TEntryList.h:26
A TEventList object is a list of selected events (entries) in a TTree.
Definition: TEventList.h:31
A ROOT file is a suite of consecutive data records (TKey instances) with a well defined format.
Definition: TFile.h:48
A TFriendElement TF describes a TTree object TF in a file.
The TH1 histogram class.
Definition: TH1.h:56
Iterator abstract base class.
Definition: TIterator.h:30
A TLeaf describes individual elements of a TBranch See TBranch structure in TTree.
Definition: TLeaf.h:32
A doubly linked list.
Definition: TList.h:44
The TNamed class is the base class for all named ROOT classes.
Definition: TNamed.h:29
An array of TObjects.
Definition: TObjArray.h:37
Int_t GetEntriesFast() const
Definition: TObjArray.h:64
Mother of all ROOT objects.
Definition: TObject.h:37
EStatusBits
Definition: TObject.h:57
A PolyMarker is defined by an array on N points in a 2-D space.
Definition: TPolyMarker.h:31
Principal Components Analysis (PCA)
Definition: TPrincipal.h:20
A TSelector object is used by the TTree::Draw, TTree::Scan, TTree::Process to navigate in a TTree and...
Definition: TSelector.h:33
Describe Streamer information for one class version.
Definition: TStreamerInfo.h:43
Class implementing or helping the various TTree cloning method.
Definition: TTreeCloner.h:38
Used to pass a selection expression to the Tree drawing routine.
Definition: TTreeFormula.h:58
Iterator on all the leaves in a TTree and its friend.
Definition: TTree.h:604
TObject * Next()
Go the next friend element.
Definition: TTree.cxx:9400
TTree * fTree
tree being iterated
Definition: TTree.h:607
Option_t * GetOption() const
Returns the object option stored in the list.
Definition: TTree.cxx:9439
TIterator & operator=(const TIterator &rhs)
Overridden assignment operator. Does NOT copy the 'cursor' location!
Definition: TTree.cxx:9377
Bool_t operator!=(const TIterator &) const
Compare two iterator objects.
Definition: TTree.h:626
TIterator * fLeafIter
current leaf sub-iterator.
Definition: TTree.h:608
TIterator * fTreeIter
current tree sub-iterator.
Definition: TTree.h:609
Bool_t fDirection
iteration direction
Definition: TTree.h:610
const TCollection * GetCollection() const
Definition: TTree.h:622
TObject * operator*() const
Return current object or nullptr.
Definition: TTree.h:634
A Tree Index with majorname and minorname.
Definition: TTreeIndex.h:28
Helper class to iterate over cluster of baskets.
Definition: TTree.h:247
Long64_t GetEstimatedClusterSize()
Estimate the cluster size.
Definition: TTree.cxx:578
Long64_t Previous()
Move on to the previous cluster and return the starting entry of this previous cluster.
Definition: TTree.cxx:659
Long64_t GetStartEntry()
Definition: TTree.h:279
Long64_t fNextEntry
Definition: TTree.h:252
Long64_t operator()()
Definition: TTree.h:288
Long64_t Next()
Move on to the next cluster and return the starting entry of this next cluster.
Definition: TTree.cxx:615
Long64_t GetNextEntry()
Definition: TTree.h:284
Long64_t fStartEntry
Definition: TTree.h:251
Long64_t fEstimatedSize
Definition: TTree.h:253
TClusterIterator(TTree *tree, Long64_t firstEntry)
Regular constructor.
Definition: TTree.cxx:527
Helper class to prevent infinite recursion in the usage of TTree Friends.
Definition: TTree.h:174
TFriendLock & operator=(const TFriendLock &)
Assignment operator.
Definition: TTree.cxx:497
TFriendLock(const TFriendLock &)
Copy constructor.
Definition: TTree.cxx:487
UInt_t fMethodBit
Definition: TTree.h:178
TTree * fTree
Definition: TTree.h:177
~TFriendLock()
Restore the state of tree the same as before we set the lock.
Definition: TTree.cxx:510
Bool_t fPrevious
Definition: TTree.h:179
A TTree object has a header with a name and a title.
Definition: TTree.h:71
virtual Int_t Fill()
Fill all branches.
Definition: TTree.cxx:4395
virtual TFriendElement * AddFriend(const char *treename, const char *filename="")
Add a TFriendElement to the list of friends.
Definition: TTree.cxx:1255
TBranchRef * fBranchRef
Branch supporting the TRefTable (if any)
Definition: TTree.h:124
virtual Int_t AddBranchToCache(const char *bname, Bool_t subbranches=kFALSE)
Add branch with name bname to the Tree cache.
Definition: TTree.cxx:1007
virtual TBranch * FindBranch(const char *name)
Return the branch that correspond to the path 'branchname', which can include the name of the tree or...
Definition: TTree.cxx:4631
virtual TVirtualPerfStats * GetPerfStats() const
Definition: TTree.h:445
virtual void SetTimerInterval(Int_t msec=333)
Definition: TTree.h:581
TTreeFormula * GetSelect()
Definition: TTree.h:451
virtual TBranch * GetBranch(const char *name)
Return pointer to the branch with the given name in this tree or its friends.
Definition: TTree.cxx:5051
virtual Int_t GetScanField() const
Definition: TTree.h:450
static Int_t GetBranchStyle()
Static function returning the current branch style.
Definition: TTree.cxx:5165
TList * fFriends
pointer to list of friend elements
Definition: TTree.h:119
virtual Long64_t GetChainEntryNumber(Long64_t entry) const
Definition: TTree.h:394
UInt_t fFriendLockStatus
! Record which method is locking the friend recursion
Definition: TTree.h:125
virtual TLeaf * GetLeafImpl(const char *branchname, const char *leafname)
Return pointer to the 1st Leaf named name in any Branch of this Tree or any branch in the list of fri...
Definition: TTree.cxx:5859
Long64_t fTotBytes
Total number of bytes in all branches before compression.
Definition: TTree.h:78
Int_t GetDefaultEntryOffsetLen() const
Definition: TTree.h:398
Int_t fMaxClusterRange
! Memory allocated for the cluster range.
Definition: TTree.h:88
virtual void Show(Long64_t entry=-1, Int_t lenmax=20)
Print values of all active leaves for entry.
Definition: TTree.cxx:8949
TEventList * fEventList
! Pointer to event selection list (if one)
Definition: TTree.h:114
virtual Long64_t GetAutoSave() const
Definition: TTree.h:387
virtual Int_t StopCacheLearningPhase()
Stop the cache learning phase.
Definition: TTree.cxx:9038
std::vector< std::pair< Long64_t, TBranch * > > fSortedBranches
! Branches to be processed in parallel when IMT is on, sorted by average task time
Definition: TTree.h:132
virtual void SetCircular(Long64_t maxEntries)
Enable/Disable circularity for this tree.
Definition: TTree.cxx:8516
virtual Long64_t GetEstimate() const
Definition: TTree.h:406
Long64_t GetDebugMax() const
Definition: TTree.h:399
Long64_t fSavedBytes
Number of autosaved bytes.
Definition: TTree.h:80
virtual TClusterIterator GetClusterIterator(Long64_t firstentry)
Return an iterator over the cluster of baskets starting at firstentry.
Definition: TTree.cxx:5227
virtual void ResetBranchAddress(TBranch *)
Tell all of our branches to set their addresses to zero.
Definition: TTree.cxx:7744
char GetNewlineValue(std::istream &inputStream)
Determine which newline this file is using.
Definition: TTree.cxx:7293
virtual Int_t CheckBranchAddressType(TBranch *branch, TClass *ptrClass, EDataType datatype, Bool_t ptr)
Check whether or not the address described by the last 3 parameters matches the content of the branch...
Definition: TTree.cxx:2722
TBranch * Branch(const char *name, T **addobj, Int_t bufsize=32000, Int_t splitlevel=99)
Definition: TTree.h:346
TIOFeatures fIOFeatures
IO features to define for newly-written baskets and branches.
Definition: TTree.h:106
virtual Long64_t GetSelectedRows()
Definition: TTree.h:452
void AddAllocationCount(UInt_t count)
Definition: TTree.h:314
virtual void SetMaxEntryLoop(Long64_t maxev=kMaxEntries)
Definition: TTree.h:559
virtual Long64_t GetEntryNumberWithIndex(Long64_t major, Long64_t minor=0) const
Return entry number corresponding to major and minor number.
Definition: TTree.cxx:5671
Long64_t fDebugMin
! First entry number to debug
Definition: TTree.h:104
virtual Long64_t SetEntries(Long64_t n=-1)
Change number of entries in the tree.
Definition: TTree.cxx:8635
TBranch * Branch(const char *name, Long_t address, const char *leaflist, Int_t bufsize=32000)
Definition: TTree.h:325
virtual TObjArray * GetListOfLeaves()
Definition: TTree.h:428
Bool_t fCacheDoClusterPrefetch
! true if cache is prefetching whole clusters
Definition: TTree.h:128
virtual TBranch * BranchOld(const char *name, const char *classname, void *addobj, Int_t bufsize=32000, Int_t splitlevel=1)
Create a new TTree BranchObject.
Definition: TTree.cxx:1955
virtual TBranch * BranchRef()
Build the optional branch supporting the TRefTable.
Definition: TTree.cxx:2209
TFile * GetCurrentFile() const
Return pointer to the current file.
Definition: TTree.cxx:5239
TObject * GetNotify() const
Definition: TTree.h:442
TList * fAliases
List of aliases for expressions based on the tree branches.
Definition: TTree.h:113
virtual TTree * CopyTree(const char *selection, Option_t *option="", Long64_t nentries=kMaxEntries, Long64_t firstentry=0)
Copy a tree with selection.
Definition: TTree.cxx:3543
virtual Int_t FlushBaskets(Bool_t create_cluster=true) const
Write to disk all the basket that have not yet been individually written and create an event cluster ...
Definition: TTree.cxx:4913
virtual Int_t Fit(const char *funcname, const char *varexp, const char *selection="", Option_t *option="", Option_t *goption="", Long64_t nentries=kMaxEntries, Long64_t firstentry=0)
Fit a projected item(s) from a tree.
Definition: TTree.cxx:4863
Int_t SetCacheSizeAux(Bool_t autocache=kTRUE, Long64_t cacheSize=0)
Set the size of the file cache and create it if possible.
Definition: TTree.cxx:8336
Long64_t * fClusterRangeEnd
[fNClusterRange] Last entry of a cluster range.
Definition: TTree.h:95
std::atomic< Long64_t > fIMTZipBytes
! Zip bytes for the IMT flush baskets.
Definition: TTree.h:149
void UseCurrentStyle()
Replace current attributes by current style.
Definition: TTree.cxx:9301
TVirtualTreePlayer * GetPlayer()
Load the TTreePlayer (if not already done).
Definition: TTree.cxx:6059
Float_t fTargetMemoryRatio
! Ratio for memory usage in uncompressed buffers versus actual occupancy.
Definition: TTree.h:134
virtual Double_t * GetIndexValues()
Definition: TTree.h:421
virtual TList * GetListOfAliases() const
Definition: TTree.h:430
virtual Long64_t ReadStream(std::istream &inputStream, const char *branchDescriptor="", char delimiter=' ')
Create or simply read branches from an input stream.
Definition: TTree.cxx:7320
virtual void SetDebug(Int_t level=1, Long64_t min=0, Long64_t max=9999999)
Set the debug level and the debug range.
Definition: TTree.cxx:8552
Int_t fScanField
Number of runs before prompting in Scan.
Definition: TTree.h:84
virtual Double_t GetWeight() const
Definition: TTree.h:483
virtual ~TTree()
Destructor.
Definition: TTree.cxx:883
virtual TTree * GetFriend(const char *) const
Return a pointer to the TTree friend whose name or alias is 'friendname.
Definition: TTree.cxx:5736
virtual Int_t SetBranchAddress(const char *bname, void *add, TBranch **ptr=0)
Change branch address, dealing with clone trees properly.
Definition: TTree.cxx:8022
TTreeFormula * GetVar(Int_t i)
Definition: TTree.h:463
virtual Double_t GetMaximum(const char *columname)
Return maximum of column with name columname.
Definition: TTree.cxx:5989
virtual Long64_t GetEntryNumberWithBestIndex(Long64_t major, Long64_t minor=0) const
Return entry number corresponding to major and minor number.
Definition: TTree.cxx:5651
static void SetMaxTreeSize(Long64_t maxsize=100000000000LL)
Set the maximum size in bytes of a Tree file (static function).
Definition: TTree.cxx:8811
virtual TBranch * BronchExec(const char *name, const char *classname, void *addobj, Bool_t isptrptr, Int_t bufsize, Int_t splitlevel)
Helper function implementing TTree::Bronch and TTree::Branch(const char *name, T &obj);.
Definition: TTree.cxx:2293
virtual Int_t UnbinnedFit(const char *funcname, const char *varexp, const char *selection="", Option_t *option="", Long64_t nentries=kMaxEntries, Long64_t firstentry=0)
Unbinned fit of one or more variable(s) from a tree.
Definition: TTree.cxx:9289
Int_t fNClusterRange
Number of Cluster range in addition to the one defined by 'AutoFlush'.
Definition: TTree.h:87
virtual void PrintCacheStats(Option_t *option="") const
Print statistics about the TreeCache for this tree.
Definition: TTree.cxx:7082
virtual Int_t BuildIndex(const char *majorname, const char *minorname="0")
Build a Tree Index (default is TTreeIndex).
Definition: TTree.cxx:2518
TVirtualTreePlayer * fPlayer
! Pointer to current Tree player
Definition: TTree.h:122
virtual void SetMakeClass(Int_t make)
Set all the branches in this TTree to be in decomposed object mode (also known as MakeClass mode).
Definition: TTree.cxx:8791
virtual void IncrementTotalBuffers(Int_t nbytes)
Definition: TTree.h:485
TObjArray fBranches
List of Branches.
Definition: TTree.h:111
TDirectory * GetDirectory() const
Definition: TTree.h:401
TTreeCache * GetReadCache(TFile *file) const
Find and return the TTreeCache registered with the file and which may contain branches for us.
Definition: TTree.cxx:6072
Bool_t fCacheUserSet
! true if the cache setting was explicitly given by user
Definition: TTree.h:129
Long64_t fEntries
Number of entries.
Definition: TTree.h:76
virtual TFile * ChangeFile(TFile *file)
Called by TTree::Fill() when file has reached its maximum fgMaxTreeSize.
Definition: TTree.cxx:2608
virtual Bool_t GetBranchStatus(const char *branchname) const
Return status of branch with name branchname.
Definition: TTree.cxx:5150
virtual TEntryList * GetEntryList()
Returns the entry list, set to this tree.
Definition: TTree.cxx:5615
virtual void SetWeight(Double_t w=1, Option_t *option="")
Set tree weight.
Definition: TTree.cxx:8938
void InitializeBranchLists(bool checkLeafCount)
Divides the top-level branches into two vectors: (i) branches to be processed sequentially and (ii) b...
Definition: TTree.cxx:5542
Long64_t * fClusterSize
[fNClusterRange] Number of entries in each cluster for a given range.
Definition: TTree.h:96
virtual Bool_t GetImplicitMT()
Definition: TTree.h:419
Long64_t fFlushedBytes
Number of auto-flushed bytes.
Definition: TTree.h:81
virtual void SetPerfStats(TVirtualPerfStats *perf)
Set perf stats.
Definition: TTree.cxx:8893
TTreeFormula * GetVar2()
Definition: TTree.h:467
std::atomic< Long64_t > fIMTTotBytes
! Total bytes for the IMT flush baskets
Definition: TTree.h:148
virtual void SetCacheLearnEntries(Int_t n=10)
Interface to TTreeCache to set the number of entries for the learning phase.
Definition: TTree.cxx:8489
void SetTargetMemoryRatio(Float_t ratio)
Definition: TTree.h:580
TEntryList * fEntryList
! Pointer to event selection list (if one)
Definition: TTree.h:115
virtual TVirtualIndex * GetTreeIndex() const
Definition: TTree.h:457
Int_t Debug() const
Definition: TTree.h:369
virtual Long64_t Merge(TCollection *list, Option_t *option="")
Merge the trees in the TList into this tree.
Definition: TTree.cxx:6659
virtual void SetMaxVirtualSize(Long64_t size=0)
Definition: TTree.h:561
virtual void DropBaskets()
Remove some baskets from memory.
Definition: TTree.cxx:4314
virtual void SetAutoSave(Long64_t autos=-300000000)
This function may be called at the start of a program to change the default value for fAutoSave (and ...
Definition: TTree.cxx:7979
virtual void SetImplicitMT(Bool_t enabled)
Definition: TTree.h:557
TBranch * Branch(const char *name, const char *classname, T **addobj, Int_t bufsize=32000, Int_t splitlevel=99)
Definition: TTree.h:341
Long64_t fMaxEntryLoop
Maximum number of entries to process.
Definition: TTree.h:90
Int_t SetBranchAddress(const char *bname, T **add, TBranch **ptr=0)
Definition: TTree.h:524
friend TBranch * TTreeBranchImpRef(TTree *tree, const char *branchname, TClass *ptrClass, EDataType datatype, void *addobj, Int_t bufsize, Int_t splitlevel)
Float_t GetTargetMemoryRatio() const
Definition: TTree.h:459
virtual void SetDirectory(TDirectory *dir)
Change the tree's directory.
Definition: TTree.cxx:8590
virtual Long64_t CopyEntries(TTree *tree, Long64_t nentries=-1, Option_t *option="")
Copy nentries from given tree to this tree.
Definition: TTree.cxx:3374
void SortBranchesByTime()
Sorts top-level branches by the last average task time recorded per branch.
Definition: TTree.cxx:5595
virtual Int_t * GetIndex()
Definition: TTree.h:420
virtual TBranchRef * GetBranchRef() const
Definition: TTree.h:389
virtual Double_t * GetV3()
Definition: TTree.h:479
virtual Long64_t Process(const char *filename, Option_t *option="", Long64_t nentries=kMaxEntries, Long64_t firstentry=0)
Process this tree executing the TSelector code in the specified filename.
Definition: TTree.cxx:7160
virtual TBranch * BranchImpRef(const char *branchname, const char *classname, TClass *ptrClass, void *addobj, Int_t bufsize, Int_t splitlevel)
Same as TTree::Branch but automatic detection of the class name.
Definition: TTree.cxx:1542
virtual void SetEventList(TEventList *list)
This function transfroms the given TEventList into a TEntryList The new TEntryList is owned by the TT...
Definition: TTree.cxx:8693
TBranch * Branch(const char *name, int address, const char *leaflist, Int_t bufsize=32000)
Definition: TTree.h:330
void MoveReadCache(TFile *src, TDirectory *dir)
Move a cache from a file to the current file in dir.
Definition: TTree.cxx:6754
TTree & operator=(const TTree &tt)=delete
Long64_t fAutoFlush
Auto-flush tree when fAutoFlush entries written or -fAutoFlush (compressed) bytes produced.
Definition: TTree.h:93
Int_t fUpdate
Update frequency for EntryLoop.
Definition: TTree.h:85
virtual void ResetAfterMerge(TFileMergeInfo *)
Resets the state of this TTree after a merge (keep the customization but forget the data).
Definition: TTree.cxx:7713
virtual void CopyAddresses(TTree *, Bool_t undo=kFALSE)
Set branch addresses of passed tree equal to ours.
Definition: TTree.cxx:3146
virtual Long64_t GetEntries() const
Definition: TTree.h:402
virtual void SetEstimate(Long64_t nentries=1000000)
Set number of entries to estimate variable limits.
Definition: TTree.cxx:8734
virtual TIterator * GetIteratorOnAllLeaves(Bool_t dir=kIterForward)
Creates a new iterator that will go through all the leaves on the tree itself and its friend.
Definition: TTree.cxx:5843
Int_t fTimerInterval
Timer interval in milliseconds.
Definition: TTree.h:83
Int_t fDebug
! Debug level
Definition: TTree.h:103
virtual Long64_t AutoSave(Option_t *option="")
AutoSave tree header every fAutoSave bytes.
Definition: TTree.cxx:1407
virtual Long64_t GetEntryNumber(Long64_t entry) const
Return entry number corresponding to entry.
Definition: TTree.cxx:5626
virtual TTree * CloneTree(Long64_t nentries=-1, Option_t *option="")
Create a clone of this tree and copy nentries.
Definition: TTree.cxx:2986
Int_t fFileNumber
! current file number (if file extensions)
Definition: TTree.h:108
virtual TLeaf * GetLeaf(const char *branchname, const char *leafname)
Return pointer to the 1st Leaf named name in any Branch of this Tree or any branch in the list of fri...
Definition: TTree.cxx:5949
virtual Long64_t GetZipBytes() const
Definition: TTree.h:484
TObjArray fLeaves
Direct pointers to individual branch leaves.
Definition: TTree.h:112
virtual void Reset(Option_t *option="")
Reset baskets, buffers and entries count in all branches and leaves.
Definition: TTree.cxx:7682
virtual void Print(Option_t *option="") const
Print a summary of the tree contents.
Definition: TTree.cxx:6962
virtual void KeepCircular()
Keep a maximum of fMaxEntries in memory.
Definition: TTree.cxx:6169
virtual void DirectoryAutoAdd(TDirectory *)
Called by TKey and TObject::Clone to automatically add us to a directory when we are read from a file...
Definition: TTree.cxx:3643
Long64_t GetCacheAutoSize(Bool_t withDefault=kFALSE) const
Used for automatic sizing of the cache.
Definition: TTree.cxx:5177
virtual Bool_t SetAlias(const char *aliasName, const char *aliasFormula)
Set a tree variable alias.
Definition: TTree.cxx:7815
Long64_t fMaxVirtualSize
Maximum total size of buffers kept in memory.
Definition: TTree.h:91
virtual Long64_t GetTotBytes() const
Definition: TTree.h:455
virtual void SetObject(const char *name, const char *title)
Change the name and title of this tree.
Definition: TTree.cxx:8848
TVirtualPerfStats * fPerfStats
! pointer to the current perf stats object
Definition: TTree.h:120
Double_t fWeight
Tree weight (see TTree::SetWeight)
Definition: TTree.h:82
virtual void SetUpdate(Int_t freq=0)
Definition: TTree.h:584
std::vector< TBranch * > fSeqBranches
! Branches to be processed sequentially when IMT is on
Definition: TTree.h:133
Long64_t fDebugMax
! Last entry number to debug
Definition: TTree.h:105
Int_t fDefaultEntryOffsetLen
Initial Length of fEntryOffset table in the basket buffers.
Definition: TTree.h:86
TTree()
Default constructor and I/O constructor.
Definition: TTree.cxx:702
Long64_t fAutoSave
Autosave tree when fAutoSave entries written or -fAutoSave (compressed) bytes produced.
Definition: TTree.h:92
TBranch * Branch(const char *name, T *obj, Int_t bufsize=32000, Int_t splitlevel=99)
Definition: TTree.h:351
virtual void SetDefaultEntryOffsetLen(Int_t newdefault, Bool_t updateExisting=kFALSE)
Update the default value for the branch's fEntryOffsetLen.
Definition: TTree.cxx:8564
std::atomic< UInt_t > fAllocationCount
indicates basket should be resized to exact memory usage, but causes significant
Definition: TTree.h:140
virtual Int_t GetEntryWithIndex(Int_t major, Int_t minor=0)
Read entry corresponding to major and minor number.
Definition: TTree.cxx:5688
static TTree * MergeTrees(TList *list, Option_t *option="")
Static function merging the trees in the TList into a new tree.
Definition: TTree.cxx:6616
TTreeFormula * GetVar4()
Definition: TTree.h:471
virtual Long64_t GetReadEntry() const
Definition: TTree.h:448
virtual TObjArray * GetListOfBranches()
Definition: TTree.h:427
virtual void SetParallelUnzip(Bool_t opt=kTRUE, Float_t RelSize=-1)
Enable or disable parallel unzipping of Tree buffers.
Definition: TTree.cxx:8879
Long64_t fZipBytes
Total number of bytes in all branches after compression.
Definition: TTree.h:79
virtual void RecursiveRemove(TObject *obj)
Make sure that obj (which is being deleted or will soon be) is no longer referenced by this TTree.
Definition: TTree.cxx:7586
virtual TTree * GetTree() const
Definition: TTree.h:456
TBuffer * fTransientBuffer
! Pointer to the current transient buffer.
Definition: TTree.h:126
virtual Double_t * GetVal(Int_t i)
Definition: TTree.h:473
Bool_t fIMTEnabled
! true if implicit multi-threading is enabled for this tree
Definition: TTree.h:130
virtual void SetEntryList(TEntryList *list, Option_t *opt="")
Set an EntryList.
Definition: TTree.cxx:8670
virtual Int_t DropBranchFromCache(const char *bname, Bool_t subbranches=kFALSE)
Remove the branch with name 'bname' from the Tree cache.
Definition: TTree.cxx:1090
virtual void AddZipBytes(Int_t zip)
Definition: TTree.h:309
virtual Long64_t LoadTree(Long64_t entry)
Set current entry.
Definition: TTree.cxx:6226
virtual Long64_t ReadFile(const char *filename, const char *branchDescriptor="", char delimiter=' ')
Create or simply read branches from filename.
Definition: TTree.cxx:7274
virtual const char * GetAlias(const char *aliasName) const
Returns the expanded value of the alias. Search in the friends if any.
Definition: TTree.cxx:5010
ROOT::TIOFeatures SetIOFeatures(const ROOT::TIOFeatures &)
Provide the end-user with the ability to enable/disable various experimental IO features for this TTr...
Definition: TTree.cxx:8754
virtual Int_t GetEntry(Long64_t entry=0, Int_t getall=0)
Read all branches of entry and return total number of bytes read.
Definition: TTree.cxx:5397
virtual TBasket * CreateBasket(TBranch *)
Create a basket for this tree and given branch.
Definition: TTree.cxx:3555
TList * fUserInfo
pointer to a list of user objects associated to this Tree
Definition: TTree.h:121
virtual Double_t GetMinimum(const char *columname)
Return minimum of column with name columname.
Definition: TTree.cxx:6029
virtual void RemoveFriend(TTree *)
Remove a friend from the list of friends.
Definition: TTree.cxx:7656
virtual Long64_t GetEntriesFast() const
Definition: TTree.h:404
virtual Double_t * GetV1()
Definition: TTree.h:475
virtual TList * GetUserInfo()
Return a pointer to the list containing user objects associated to this tree.
Definition: TTree.cxx:6110
virtual void SetNotify(TObject *obj)
Sets the address of the object to be notified when the tree is loaded.
Definition: TTree.h:574
TEventList * GetEventList() const
Definition: TTree.h:412
@ kSplitCollectionOfPointers
Definition: TTree.h:243
Int_t SetBranchAddress(const char *bname, T *add, TBranch **ptr=0)
Definition: TTree.h:533
Long64_t fChainOffset
! Offset of 1st entry of this Tree in a TChain
Definition: TTree.h:98
@ kOnlyFlushAtCluster
Definition: TTree.h:236
@ kCircular
Definition: TTree.h:235
@ kForceRead
Definition: TTree.h:234
virtual Long64_t GetEntriesFriend() const
Return pointer to the 1st Leaf named name in any Branch of this Tree or any branch in the list of fri...
Definition: TTree.cxx:5272
virtual TSQLResult * Query(const char *varexp="", const char *selection="", Option_t *option="", Long64_t nentries=kMaxEntries, Long64_t firstentry=0)
Loop over entries and return a TSQLResult object containing entries following selection.
Definition: TTree.cxx:7223
virtual TBranch * Bronch(const char *name, const char *classname, void *addobj, Int_t bufsize=32000, Int_t splitlevel=99)
Create a new TTree BranchElement.
Definition: TTree.cxx:2285
virtual void SetBasketSize(const char *bname, Int_t buffsize=16000)
Set a branch's basket size.
Definition: TTree.cxx:7995
static void SetBranchStyle(Int_t style=1)
Set the current branch style.
Definition: TTree.cxx:8294
virtual Long64_t GetReadEvent() const
Definition: TTree.h:449
void ImportClusterRanges(TTree *fromtree)
Appends the cluster range information stored in 'fromtree' to this tree, including the value of fAuto...
Definition: TTree.cxx:6126
Long64_t fEstimate
Number of entries to estimate histogram limits.
Definition: TTree.h:94
TH1 * GetHistogram()
Definition: TTree.h:418
UInt_t GetAllocationCount() const
Definition: TTree.h:382
Int_t FlushBasketsImpl() const
Internal implementation of the FlushBaskets algorithm.
Definition: TTree.cxx:4930
Long64_t GetDebugMin() const
Definition: TTree.h:400
virtual Long64_t LoadTreeFriend(Long64_t entry, TTree *T)
Load entry on behalf of our master tree, we may use an index.
Definition: TTree.cxx:6322
TVirtualIndex * fTreeIndex
Pointer to the tree Index (if any)
Definition: TTree.h:118
virtual void Browse(TBrowser *)
Browse content of the TTree.
Definition: TTree.cxx:2490
virtual Int_t GetTreeNumber() const
Definition: TTree.h:458
TObject * fNotify
! Object to be notified when loading a Tree
Definition: TTree.h:109
virtual TBranch * BranchImp(const char *branchname, const char *classname, TClass *ptrClass, void *addobj, Int_t bufsize, Int_t splitlevel)
Same as TTree::Branch() with added check that addobj matches className.
Definition: TTree.cxx:1461
virtual TList * GetListOfClones()
Definition: TTree.h:426
Long64_t fCacheSize
! Maximum size of file buffers
Definition: TTree.h:97
TList * fClones
! List of cloned trees which share our addresses
Definition: TTree.h:123
std::atomic< Long64_t > fTotalBuffers
! Total number of bytes in branch buffers
Definition: TTree.h:100
Bool_t fCacheDoAutoInit
! true if cache auto creation or resize check is needed
Definition: TTree.h:127
virtual Int_t MakeSelector(const char *selector=0, Option_t *option="")
Generate skeleton selector class for this tree.
Definition: TTree.cxx:6587
ELockStatusBits
Definition: TTree.h:197
@ kFindBranch
Definition: TTree.h:198
@ kFindLeaf
Definition: TTree.h:199
@ kGetEntryWithIndex
Definition: TTree.h:203
@ kPrint
Definition: TTree.h:208
@ kGetFriend
Definition: TTree.h:204
@ kGetBranch
Definition: TTree.h:201
@ kSetBranchStatus
Definition: TTree.h:210
@ kLoadTree
Definition: TTree.h:207
@ kGetEntry
Definition: TTree.h:202
@ kGetLeaf
Definition: TTree.h:206
@ kRemoveFriend
Definition: TTree.h:209
@ kGetFriendAlias
Definition: TTree.h:205
@ kGetAlias
Definition: TTree.h:200
virtual Double_t * GetV4()
Definition: TTree.h:481
TBranch * Branch(const char *name, const char *classname, T *obj, Int_t bufsize=32000, Int_t splitlevel=99)
Definition: TTree.h:336
virtual void Draw(Option_t *opt)
Default Draw method for all objects.
Definition: TTree.h:371
virtual Int_t MakeClass(const char *classname=0, Option_t *option="")
Generate a skeleton analysis class for this tree.
Definition: TTree.cxx:6372
TTreeFormula * GetVar3()
Definition: TTree.h:469
virtual void SetTreeIndex(TVirtualIndex *index)
The current TreeIndex is replaced by the new index.
Definition: TTree.cxx:8910
virtual void OptimizeBaskets(ULong64_t maxMemory=10000000, Float_t minComp=1.1, Option_t *option="")
This function may be called after having filled some entries in a Tree.
Definition: TTree.cxx:6800
virtual Long64_t Project(const char *hname, const char *varexp, const char *selection="", Option_t *option="", Long64_t nentries=kMaxEntries, Long64_t firstentry=0)
Make a projection of a tree using selections.
Definition: TTree.cxx:7208
virtual Int_t SetCacheEntryRange(Long64_t first, Long64_t last)
interface to TTreeCache to set the cache entry range
Definition: TTree.cxx:8455
static Long64_t GetMaxTreeSize()
Static function which returns the tree file size limit in bytes.
Definition: TTree.cxx:6019
Int_t SetBranchAddressImp(TBranch *branch, void *addr, TBranch **ptr)
Change branch address, dealing with clone trees properly.
Definition: TTree.cxx:8079
virtual Int_t GetTimerInterval() const
Definition: TTree.h:453
virtual void SetScanField(Int_t n=50)
Definition: TTree.h:579
TTree(const TTree &tt)=delete
Long64_t fMaxEntries
Maximum number of entries in case of circular buffers.
Definition: TTree.h:89
TBranch * Branch(const char *name, char *address, const char *leaflist, Int_t bufsize=32000)
Definition: TTree.h:320
virtual void DropBuffers(Int_t nbytes)
Drop branch buffers to accommodate nbytes below MaxVirtualsize.
Definition: TTree.cxx:4327
virtual void SetName(const char *name)
Change the name of this tree.
Definition: TTree.cxx:8819
virtual void Delete(Option_t *option="")
Delete this tree from memory or/and disk.
Definition: TTree.cxx:3571
virtual TList * GetListOfFriends() const
Definition: TTree.h:429
virtual void Refresh()
Refresh contents of this tree and its branches from the current status on disk.
Definition: TTree.cxx:7617
virtual void SetAutoFlush(Long64_t autof=-30000000)
This function may be called at the start of a program to change the default value for fAutoFlush.
Definition: TTree.cxx:7870
static Long64_t fgMaxTreeSize
Maximum size of a file containing a Tree.
Definition: TTree.h:143
Long64_t fReadEntry
! Number of the entry being processed
Definition: TTree.h:99
TArrayD fIndexValues
Sorted index values.
Definition: TTree.h:116
void MarkEventCluster()
Mark the previous event as being at the end of the event cluster.
Definition: TTree.cxx:7932
virtual Int_t GetNbranches()
Definition: TTree.h:441
virtual Int_t MakeCode(const char *filename=0)
Generate a skeleton function for this tree.
Definition: TTree.cxx:6405
UInt_t fNEntriesSinceSorting
! Number of entries processed since the last re-sorting of branches
Definition: TTree.h:131
virtual Int_t MakeProxy(const char *classname, const char *macrofilename=0, const char *cutfilename=0, const char *option=0, Int_t maxUnrolling=3)
Generate a skeleton analysis class for this Tree using TBranchProxy.
Definition: TTree.cxx:6533
virtual void SetFileNumber(Int_t number=0)
Set fFileNumber to number.
Definition: TTree.cxx:8777
virtual TLeaf * FindLeaf(const char *name)
Find leaf..
Definition: TTree.cxx:4703
Int_t GetEvent(Long64_t entry=0, Int_t getall=0)
Definition: TTree.h:408
virtual void StartViewer()
Start the TTreeViewer on this tree.
Definition: TTree.cxx:9023
Int_t GetMakeClass() const
Definition: TTree.h:434
TDirectory * fDirectory
! Pointer to directory holding this tree
Definition: TTree.h:110
ESetBranchAddressStatus
Definition: TTree.h:218
@ kClassMismatch
Definition: TTree.h:223
@ kVoidPtr
Definition: TTree.h:228
@ kNoCheck
Definition: TTree.h:229
@ kMatchConversionCollection
Definition: TTree.h:226
@ kMissingCompiledCollectionProxy
Definition: TTree.h:221
@ kMismatch
Definition: TTree.h:222
@ kMatchConversion
Definition: TTree.h:225
@ kInternalError
Definition: TTree.h:220
@ kMatch
Definition: TTree.h:224
@ kMissingBranch
Definition: TTree.h:219
@ kMakeClass
Definition: TTree.h:227
static Int_t fgBranchStyle
Old/New branch style.
Definition: TTree.h:142
virtual void ResetBranchAddresses()
Tell all of our branches to drop their current objects and allocate new ones.
Definition: TTree.cxx:7754
Int_t fNfill
! Local for EntryLoop
Definition: TTree.h:102
virtual Long64_t GetCacheSize() const
Definition: TTree.h:392
TArrayI fIndex
Index of sorted values.
Definition: TTree.h:117
Bool_t IsFolder() const
Returns kTRUE in case object contains browsable objects (like containers or lists of other objects).
Definition: TTree.h:486
virtual Int_t GetPacketSize() const
Definition: TTree.h:444
virtual Int_t SetCacheSize(Long64_t cachesize=-1)
Set maximum size of the file cache .
Definition: TTree.cxx:8310
void AddClone(TTree *)
Add a cloned tree to our list of trees to be notified whenever we change our branch addresses or when...
Definition: TTree.cxx:1167
virtual void SetBranchStatus(const char *bname, Bool_t status=1, UInt_t *found=0)
Set branch status to Process or DoNotProcess.
Definition: TTree.cxx:8168
TBuffer * GetTransientBuffer(Int_t size)
Returns the transient buffer currently used by this TTree for reading/writing baskets.
Definition: TTree.cxx:985
ROOT::TIOFeatures GetIOFeatures() const
Returns the current set of IO settings.
Definition: TTree.cxx:5835
virtual Int_t GetFileNumber() const
Definition: TTree.h:415
virtual const char * GetFriendAlias(TTree *) const
If the 'tree' is a friend, this method returns its alias name.
Definition: TTree.cxx:5793
virtual void SetChainOffset(Long64_t offset=0)
Definition: TTree.h:545
virtual Bool_t GetClusterPrefetch() const
Definition: TTree.h:396
virtual Bool_t Notify()
Function called when loading a new class library.
Definition: TTree.cxx:6776
virtual Double_t * GetW()
Definition: TTree.h:482
Bool_t MemoryFull(Int_t nbytes)
Check if adding nbytes to memory we are still below MaxVirtualsize.
Definition: TTree.cxx:6602
TTreeFormula * GetVar1()
Definition: TTree.h:465
virtual Double_t * GetV2()
Definition: TTree.h:477
Int_t fPacketSize
! Number of entries in one packet for parallel root
Definition: TTree.h:101
virtual Int_t Branch(TCollection *list, Int_t bufsize=32000, Int_t splitlevel=99, const char *name="")
Create one branch for each element in the collection.
Definition: TTree.cxx:1722
virtual Int_t GetUpdate() const
Definition: TTree.h:460
virtual Long64_t GetChainOffset() const
Definition: TTree.h:395
virtual Int_t Write(const char *name=0, Int_t option=0, Int_t bufsize=0)
Write this object to the current directory.
Definition: TTree.cxx:9338
TStreamerInfo * BuildStreamerInfo(TClass *cl, void *pointer=0, Bool_t canOptimize=kTRUE)
Build StreamerInfo for class cl.
Definition: TTree.cxx:2533
virtual Long64_t Scan(const char *varexp="", const char *selection="", Option_t *option="", Long64_t nentries=kMaxEntries, Long64_t firstentry=0)
Loop over tree entries and print entries passing selection.
Definition: TTree.cxx:7773
virtual Long64_t GetMaxEntryLoop() const
Definition: TTree.h:436
Bool_t fIMTFlush
! True if we are doing a multithreaded flush.
Definition: TTree.h:147
virtual void SetClusterPrefetch(Bool_t enabled)
Definition: TTree.h:547
virtual void AddTotBytes(Int_t tot)
Definition: TTree.h:308
Int_t fMakeClass
! not zero when processing code generated by MakeClass
Definition: TTree.h:107
virtual Int_t LoadBaskets(Long64_t maxmemory=2000000000)
Read in memory all baskets from all branches up to the limit of maxmemory bytes.
Definition: TTree.cxx:6205
static constexpr Long64_t kMaxEntries
Definition: TTree.h:215
TPrincipal * Principal(const char *varexp="", const char *selection="", Option_t *option="np", Long64_t nentries=kMaxEntries, Long64_t firstentry=0)
Interface to the Principal Components Analysis class.
Definition: TTree.cxx:6943
virtual Long64_t GetAutoFlush() const
Definition: TTree.h:386
virtual Long64_t GetMaxVirtualSize() const
Definition: TTree.h:439
Abstract interface for Tree Index.
Definition: TVirtualIndex.h:29
Provides the interface for the PROOF internal performance measurement and event tracing.
Abstract base class defining the interface for the plugins that implement Draw, Scan,...
virtual TTreeFormula * GetVar1() const =0
virtual Double_t * GetV4() const =0
virtual Double_t * GetW() const =0
virtual TTreeFormula * GetVar4() const =0
virtual TTreeFormula * GetVar(Int_t) const =0
virtual Double_t * GetVal(Int_t) const =0
virtual TTreeFormula * GetVar2() const =0
virtual Double_t * GetV1() const =0
static constexpr Long64_t kMaxEntries
virtual TTreeFormula * GetVar3() const =0
virtual Double_t * GetV2() const =0
virtual TTreeFormula * GetSelect() const =0
virtual TH1 * GetHistogram() const =0
virtual Long64_t GetSelectedRows() const =0
virtual Double_t * GetV3() const =0
const Int_t n
Definition: legend1.C:16
double T(double x)
Definition: ChebyshevPol.h:34
constexpr std::array< decltype(std::declval< F >()(std::declval< int >())), N > make(F f)
Definition: file.py:1
Definition: first.py:1
Definition: tree.py:1
TCanvas * style()
Definition: style.C:1
auto * tt
Definition: textangle.C:16