ROOT  6.07/01
Reference Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
TBranchClones.cxx
Go to the documentation of this file.
1 // @(#)root/tree:$Id$
2 // Author: Rene Brun 11/02/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 #include "TBranchClones.h"
13 
14 #include "TBasket.h"
15 #include "TClass.h"
16 #include "TClonesArray.h"
17 #include "TDataMember.h"
18 #include "TDataType.h"
19 #include "TFile.h"
20 #include "TLeafI.h"
21 #include "TRealData.h"
22 #include "TTree.h"
23 
24 #include <cstring>
25 
27 
28 /** \class TBranchClones
29 A Branch for the case of an array of clone objects.
30 
31 See TTree.
32 */
33 
34 ////////////////////////////////////////////////////////////////////////////////
35 /// Default and i/o constructor.
36 
38 : TBranch()
39 , fList(0)
40 , fRead(0)
41 , fN(0)
42 , fNdataMax(0)
43 , fBranchCount(0)
44 {
45 }
46 
47 ////////////////////////////////////////////////////////////////////////////////
48 /// Constructor.
49 
50 TBranchClones::TBranchClones(TTree *tree, const char* name, void* pointer, Int_t basketsize, Int_t compress, Int_t splitlevel)
51 : TBranch()
52 , fList(0)
53 , fRead(0)
54 , fN(0)
55 , fNdataMax(0)
56 , fBranchCount(0)
57 {
58  Init(tree,0,name,pointer,basketsize,compress,splitlevel);
59 }
60 
61 ////////////////////////////////////////////////////////////////////////////////
62 /// Constructor.
63 
64 TBranchClones::TBranchClones(TBranch *parent, const char* name, void* pointer, Int_t basketsize, Int_t compress, Int_t splitlevel)
65 : TBranch()
66 , fList(0)
67 , fRead(0)
68 , fN(0)
69 , fNdataMax(0)
70 , fBranchCount(0)
71 {
72  Init(0,parent,name,pointer,basketsize,compress,splitlevel);
73 }
74 
75 ////////////////////////////////////////////////////////////////////////////////
76 /// Initialization (non-virtual, to be called from constructor).
77 
78 void TBranchClones::Init(TTree *tree, TBranch *parent, const char* name, void* pointer, Int_t basketsize, Int_t compress, Int_t splitlevel)
79 {
80  if (tree==0 && parent!=0) tree = parent->GetTree();
81  fTree = tree;
82  fMother = parent ? parent->GetMother() : this;
83  fParent = parent;
84 
85  TString leaflist;
86  TString branchname;
87  TString branchcount;
88  SetName(name);
89  if ((compress == -1) && tree->GetDirectory()) {
90  TFile* bfile = 0;
91  if (tree->GetDirectory()) {
92  bfile = tree->GetDirectory()->GetFile();
93  }
94  if (bfile) {
95  compress = bfile->GetCompressionSettings();
96  }
97  }
98  char* cpointer = (char*) pointer;
99  char** ppointer = (char**) pointer;
100  fList = (TClonesArray*) *ppointer;
101  fAddress = cpointer;
102  TClass* cl = fList->GetClass();
103  if (!cl) {
104  return;
105  }
106  tree->BuildStreamerInfo(cl);
107  fClassName = cl->GetName();
108  fSplitLevel = splitlevel;
109 
110  // Create a branch to store the array count.
111  if (basketsize < 100) {
112  basketsize = 100;
113  }
114  leaflist.Form("%s_/I", name);
115  branchcount.Form("%s_", name);
116  fBranchCount = new TBranch(this, branchcount, &fN, leaflist, basketsize);
117  fBranchCount->SetBit(kIsClone);
118  TLeaf* leafcount = (TLeaf*) fBranchCount->GetListOfLeaves()->UncheckedAt(0);
120  fFileName = "";
121 
122  // Loop on all public data members of the class and its base classes.
123  const char* itype = 0;
124  TRealData* rd = 0;
126  while ((rd = (TRealData *) next())) {
127  if (rd->TestBit(TRealData::kTransient)) continue;
128 
129  if (rd->IsObject()) {
130  continue;
131  }
132  TDataMember* member = rd->GetDataMember();
133  if (!member->IsPersistent()) {
134  // -- Skip non-persistent members.
135  continue;
136  }
137  if (!member->IsBasic() || member->IsaPointer()) {
138  Warning("BranchClones", "Cannot process: %s::%s", cl->GetName(), member->GetName());
139  continue;
140  }
141  // Forget TObject part if splitlevel = 2.
142  if ((splitlevel > 1) || fList->TestBit(TClonesArray::kForgetBits) || cl->CanIgnoreTObjectStreamer()) {
143  if (!std::strcmp(member->GetName(), "fBits")) {
144  continue;
145  }
146  if (!std::strcmp(member->GetName(), "fUniqueID")) {
147  continue;
148  }
149  }
151  TDataType* membertype = member->GetDataType();
152  Int_t type = membertype->GetType();
153  if (!type) {
154  Warning("BranchClones", "Cannot process: %s::%s of type zero!", cl->GetName(), member->GetName());
155  continue;
156  }
157 
158  if (type == 1) {
159  itype = "B";
160  } else if (type == 2) {
161  itype = "S";
162  } else if (type == 3) {
163  itype = "I";
164  } else if (type == 5) {
165  itype = "F";
166  } else if (type == 8) {
167  itype = "D";
168  } else if (type == 9) {
169  itype = "D";
170  } else if (type == 11) {
171  itype = "b";
172  } if (type == 12) {
173  itype = "s";
174  } if (type == 13) {
175  itype = "i";
176  }
177 
178  leaflist.Form("%s[%s]/%s", member->GetName(), branchcount.Data(), itype);
179  Int_t comp = compress;
180  branchname.Form("%s.%s", name, rd->GetName());
181  TBranch* branch = new TBranch(this, branchname, this, leaflist, basketsize, comp);
182  branch->SetBit(kIsClone);
183  TObjArray* leaves = branch->GetListOfLeaves();
184  TLeaf* leaf = (TLeaf*) leaves->UncheckedAt(0);
185  leaf->SetOffset(rd->GetThisOffset());
186  leaf->SetLeafCount(leafcount);
187  Int_t arraydim = member->GetArrayDim();
188  if (arraydim) {
189  Int_t maxindex = 1;
190  while (arraydim) {
191  maxindex *= member->GetMaxIndex(--arraydim);
192  }
193  leaf->SetLen(maxindex);
194  }
195  fBranches.Add(branch);
196  }
197 }
198 
199 ////////////////////////////////////////////////////////////////////////////////
200 /// Destructor.
201 
203 {
204  delete fBranchCount;
205  fBranchCount = 0;
206  fBranches.Delete();
207  // FIXME: We might own this, possible memory leak.
208  fList = 0;
209 }
210 
211 ////////////////////////////////////////////////////////////////////////////////
212 /// Browse this branch.
213 
215 {
216  fBranches.Browse(b);
217 }
218 
219 ////////////////////////////////////////////////////////////////////////////////
220 /// Loop on all branches and fill Basket buffer.
221 
223 {
224  Int_t i = 0;
225  Int_t nbytes = 0;
226  Int_t nbranches = fBranches.GetEntriesFast();
227  char** ppointer = (char**) fAddress;
228  if (!ppointer) {
229  return 0;
230  }
231  fList = (TClonesArray*) *ppointer;
232  fN = fList->GetEntriesFast();
233  fEntries++;
234  if (fN > fNdataMax) {
235  fNdataMax = fList->GetSize();
236  TString branchcount;
237  branchcount.Form("%s_", GetName());
238  TLeafI* leafi = (TLeafI*) fBranchCount->GetLeaf(branchcount);
239  leafi->SetMaximum(fNdataMax);
240  for (i = 0; i < nbranches; i++) {
241  TBranch* branch = (TBranch*) fBranches.UncheckedAt(i);
242  TObjArray* leaves = branch->GetListOfLeaves();
243  TLeaf* leaf = (TLeaf*) leaves->UncheckedAt(0);
244  leaf->SetAddress();
245  }
246  }
247  nbytes += fBranchCount->Fill();
248  for (i = 0; i < nbranches; i++) {
249  TBranch* branch = (TBranch*) fBranches.UncheckedAt(i);
250  TObjArray* leaves = branch->GetListOfLeaves();
251  TLeaf* leaf = (TLeaf*) leaves->UncheckedAt(0);
252  leaf->Import(fList, fN);
253  nbytes += branch->Fill();
254  }
255  return nbytes;
256 }
257 
258 ////////////////////////////////////////////////////////////////////////////////
259 /// Read all branches and return total number of bytes read.
260 
262 {
263  if (TestBit(kDoNotProcess) && !getall) {
264  return 0;
265  }
266  Int_t nbytes = fBranchCount->GetEntry(entry, getall);
267  TLeaf* leafcount = (TLeaf*) fBranchCount->GetListOfLeaves()->UncheckedAt(0);
268  fN = Int_t(leafcount->GetValue());
269  if (fN <= 0) {
270  if (fList) {
271  fList->Clear();
272  }
273  return 0;
274  }
275  TBranch* branch = 0;
276  Int_t nbranches = fBranches.GetEntriesFast();
277  // If fList exists, create clones array objects.
278  if (fList) {
279  fList->Clear();
281  for (Int_t i = 0; i < nbranches; i++) {
282  branch = (TBranch*) fBranches.UncheckedAt(i);
283  if (((TLeaf*) branch->GetListOfLeaves()->UncheckedAt(0))->GetOffset() < 0) {
284  continue;
285  }
286  nbytes += branch->GetEntryExport(entry, getall, fList, fN);
287  }
288  } else {
289  for (Int_t i = 0; i < nbranches; i++) {
290  branch = (TBranch*) fBranches.UncheckedAt(i);
291  nbytes += branch->GetEntry(entry, getall);
292  }
293  }
294  return nbytes;
295 }
296 
297 ////////////////////////////////////////////////////////////////////////////////
298 /// Print branch parameters.
299 
300 void TBranchClones::Print(Option_t *option) const
301 {
302  fBranchCount->Print(option);
303  Int_t nbranches = fBranches.GetEntriesFast();
304  for (Int_t i = 0; i < nbranches; i++) {
305  TBranch* branch = (TBranch*) fBranches.At(i);
306  branch->Print(option);
307  }
308 }
309 
310 ////////////////////////////////////////////////////////////////////////////////
311 /// Reset branch.
312 ///
313 /// - Existing buffers are deleted
314 /// - Entries, max and min are reset
315 
317 {
318  fEntries = 0;
319  fTotBytes = 0;
320  fZipBytes = 0;
321  Int_t nbranches = fBranches.GetEntriesFast();
322  for (Int_t i = 0; i < nbranches; i++) {
323  TBranch* branch = (TBranch*) fBranches.At(i);
324  branch->Reset(option);
325  }
326  fBranchCount->Reset();
327 }
328 
329 ////////////////////////////////////////////////////////////////////////////////
330 /// Reset branch after a merge.
331 ///
332 /// - Existing buffers are deleted
333 /// - Entries, max and min are reset
334 
336 {
337  fEntries = 0;
338  fTotBytes = 0;
339  fZipBytes = 0;
340  Int_t nbranches = fBranches.GetEntriesFast();
341  for (Int_t i = 0; i < nbranches; i++) {
342  TBranch* branch = (TBranch*) fBranches.At(i);
343  branch->ResetAfterMerge(info);
344  }
345  fBranchCount->ResetAfterMerge(info);
346 }
347 
348 ////////////////////////////////////////////////////////////////////////////////
349 /// Set address of this branch.
350 
352 {
353  fReadEntry = -1;
354  fAddress = (char*) addr;
355  char** pp= (char**) fAddress;
356  if (pp && (*pp == 0)) {
357  // We've been asked to allocate an object for the user.
358  *pp= (char*) new TClonesArray(fClassName);
359  }
360  fList = 0;
361  if (pp) {
362  fList = (TClonesArray*) *pp;
363  }
364  fBranchCount->SetAddress(&fN);
365 }
366 
367 ////////////////////////////////////////////////////////////////////////////////
368 /// Reset basket size for all sub-branches.
369 
371 {
372  TBranch::SetBasketSize(buffsize);
373 
374  Int_t nbranches = fBranches.GetEntriesFast();
375  for (Int_t i = 0; i < nbranches; i++) {
376  TBranch* branch = (TBranch*) fBranches[i];
377  branch->SetBasketSize(fBasketSize);
378  }
379 }
380 
381 ////////////////////////////////////////////////////////////////////////////////
382 /// Serialize/Deserialize from a buffer.
383 
384 void TBranchClones::Streamer(TBuffer& b)
385 {
386  UInt_t R__s, R__c;
387  if (b.IsReading()) {
388  b.ReadVersion(&R__s, &R__c);
389  TNamed::Streamer(b);
390  b >> fCompress;
391  b >> fBasketSize;
392  b >> fEntryOffsetLen;
393  b >> fMaxBaskets;
394  b >> fWriteBasket;
395  b >> fEntryNumber;
396  b >> fEntries;
397  b >> fTotBytes;
398  b >> fZipBytes;
399  b >> fOffset;
400  b >> fBranchCount;
401  fClassName.Streamer(b);
402  fBranches.Streamer(b);
403  fTree = 0;
404  TBranch* branch = 0;
405  TLeaf* leaf = 0;
406  Int_t nbranches = fBranches.GetEntriesFast();
407  for (Int_t i = 0; i < nbranches; i++) {
408  branch = (TBranch*) fBranches[i];
409  branch->SetBit(kIsClone);
410  leaf = (TLeaf*) branch->GetListOfLeaves()->UncheckedAt(0);
411  leaf->SetOffset(-1);
412  }
413  fRead = 1;
414  TClass* cl = TClass::GetClass((const char*) fClassName);
415  if (!cl) {
416  Warning("Streamer", "Unknown class: %s. Cannot read BranchClones: %s", fClassName.Data(), GetName());
418  return;
419  }
420  if (!cl->GetListOfRealData()) {
421  cl->BuildRealData();
422  }
423  TString branchname;
424  TRealData* rd = 0;
426  while ((rd = (TRealData*) next())) {
427  if (rd->TestBit(TRealData::kTransient)) continue;
428 
429  TDataMember* member = rd->GetDataMember();
430  if (!member || !member->IsBasic() || !member->IsPersistent()) {
431  continue;
432  }
433  TDataType* membertype = member->GetDataType();
434  if (!membertype->GetType()) {
435  continue;
436  }
437  branchname.Form("%s.%s", GetName(), rd->GetName());
438  branch = (TBranch*) fBranches.FindObject(branchname);
439  if (!branch) {
440  continue;
441  }
442  TObjArray* leaves = branch->GetListOfLeaves();
443  leaf = (TLeaf*) leaves->UncheckedAt(0);
444  leaf->SetOffset(rd->GetThisOffset());
445  }
446  b.CheckByteCount(R__s, R__c, TBranchClones::IsA());
447  } else {
449  TNamed::Streamer(b);
450  b << fCompress;
451  b << fBasketSize;
452  b << fEntryOffsetLen;
453  b << fMaxBaskets;
454  b << fWriteBasket;
455  b << fEntryNumber;
456  b << fEntries;
457  b << fTotBytes;
458  b << fZipBytes;
459  b << fOffset;
460  b << fBranchCount;
461  fClassName.Streamer(b);
462  fBranches.Streamer(b);
463  b.SetByteCount(R__c, kTRUE);
464  }
465 }
466 
467 ////////////////////////////////////////////////////////////////////////////////
468 /// Refresh the value of fDirectory (i.e. where this branch writes/reads its buffers)
469 /// with the current value of fTree->GetCurrentFile unless this branch has been
470 /// redirected to a different file. Also update the sub-branches.
471 
473 {
474  fBranchCount->UpdateFile();
476 }
A TLeaf describes individual elements of a TBranch See TBranch structure in TTree.
Definition: TLeaf.h:37
virtual Int_t Fill()
Loop on all branches and fill Basket buffer.
TStreamerInfo * BuildStreamerInfo(TClass *cl, void *pointer=0, Bool_t canOptimize=kTRUE)
Build StreamerInfo for class cl.
Definition: TTree.cxx:2523
An array of TObjects.
Definition: TObjArray.h:39
virtual void SetAddress(void *add)
Set address of this branch.
virtual void UpdateFile()
Refresh the value of fDirectory (i.e.
Definition: TBranch.cxx:2644
Int_t fOffset
Definition: TBranch.h:74
long long Long64_t
Definition: RtypesCore.h:69
TString fClassName
Maximum value of fN.
Definition: TBranchClones.h:38
Bool_t IsReading() const
Definition: TBuffer.h:83
Int_t GetType() const
Definition: TDataType.h:70
ClassImp(TSeqCollection) Int_t TSeqCollection TIter next(this)
Return index of object in collection.
Long64_t fEntries
Pointer to the current basket.
Definition: TBranch.h:84
const char Option_t
Definition: RtypesCore.h:62
virtual void Delete(Option_t *option="")
Remove all objects from the array AND delete all heap based objects.
Definition: TObjArray.cxx:329
All ROOT classes may have RTTI (run time type identification) support added.
Definition: TDataMember.h:33
Long64_t fZipBytes
Definition: TBranch.h:87
virtual Int_t GetEntry(Long64_t entry=0, Int_t getall=0)
Read all branches and return total number of bytes read.
virtual void SetName(const char *name)
Change (i.e.
Definition: TNamed.cxx:128
A ROOT file is a suite of consecutive data records (TKey instances) with a well defined format...
Definition: TFile.h:45
virtual void Print(Option_t *option="") const
Print TBranch parameters.
Definition: TBranch.cxx:1727
Buffer base class used for serializing objects.
Definition: TBuffer.h:42
Bool_t IsPersistent() const
Definition: TDataMember.h:89
virtual Int_t CheckByteCount(UInt_t startpos, UInt_t bcnt, const TClass *clss)=0
Int_t fRead
Pointer to the clonesarray.
Definition: TBranchClones.h:35
Basic string class.
Definition: TString.h:137
TBranch * fBranchCount
Definition: TBranchClones.h:39
virtual void Import(TClonesArray *, Int_t)
Definition: TLeaf.h:88
int Int_t
Definition: RtypesCore.h:41
TDataType * GetDataType() const
Definition: TDataMember.h:74
Bool_t IsaPointer() const
Return true if data member is a pointer.
Int_t GetEntriesFast() const
Definition: TObjArray.h:66
virtual UInt_t WriteVersion(const TClass *cl, Bool_t useBcnt=kFALSE)=0
Int_t GetMaxIndex(Int_t dim) const
Return maximum index for array dimension "dim".
virtual ~TBranchClones()
Destructor.
const char * GetFullTypeName() const
Get full type description of data member, e,g.: "class TDirectory*".
void SetBit(UInt_t f, Bool_t set)
Set or unset the user status bits as specified in f.
Definition: TObject.cxx:732
Long64_t fEntryNumber
Definition: TBranch.h:73
TList * GetListOfRealData() const
Definition: TClass.h:404
const char * Data() const
Definition: TString.h:349
virtual TObject * FindObject(const char *name) const
Find an object in this collection using its name.
Definition: TObjArray.cxx:396
virtual void UpdateFile()
Refresh the value of fDirectory (i.e.
Int_t fWriteBasket
Definition: TBranch.h:72
friend class TClonesArray
Definition: TObject.h:214
Long64_t fTotBytes
Definition: TBranch.h:86
Int_t GetOffset() const
Definition: TBranch.h:167
virtual void SetLen(Int_t len=1)
Definition: TLeaf.h:102
const Int_t kDoNotProcess
Definition: TBranch.h:52
Int_t fMaxBaskets
Definition: TBranch.h:75
Bool_t IsObject() const
Definition: TRealData.h:60
virtual void SetAddress(void *add=0)
Definition: TLeaf.h:124
virtual Double_t GetValue(Int_t i=0) const
Definition: TLeaf.h:122
Int_t fSplitLevel
Number of baskets in memory.
Definition: TBranch.h:77
virtual void Clear(Option_t *option="")
Clear the clones array.
virtual void ResetAfterMerge(TFileMergeInfo *)
Reset a Branch.
Definition: TBranch.cxx:1965
virtual TFile * GetFile() const
Definition: TDirectory.h:155
virtual Int_t Fill()
Loop on all leaves of this branch to fill Basket buffer.
Definition: TBranch.cxx:724
TObject * UncheckedAt(Int_t i) const
Definition: TObjArray.h:91
void BuildRealData(void *pointer=0, Bool_t isTransient=kFALSE)
Build a full list of persistent data members.
Definition: TClass.cxx:1933
Using a TBrowser one can browse all ROOT objects.
Definition: TBrowser.h:41
virtual Int_t GetEntryExport(Long64_t entry, Int_t getall, TClonesArray *list, Int_t n)
Read all leaves of an entry and export buffers to real objects in a TClonesArray list.
Definition: TBranch.cxx:1291
Int_t fBasketSize
Definition: TBranch.h:70
Basic data type descriptor (datatype information is obtained from CINT).
Definition: TDataType.h:46
TDirectory * GetDirectory() const
Definition: TTree.h:385
TClass * IsA() const
TBranch * GetMother() const
Get our top-level parent branch in the tree.
Definition: TBranch.cxx:1533
const Int_t kIsClone
Definition: TBranch.h:53
void Form(const char *fmt,...)
Formats a string using a printf style format descriptor.
Definition: TString.cxx:2308
virtual void SetBasketSize(Int_t buffsize)
Reset basket size for all sub-branches.
unsigned int UInt_t
Definition: RtypesCore.h:42
Bool_t TestBit(UInt_t f) const
Definition: TObject.h:173
The TRealData class manages the effective list of all data members for a given class.
Definition: TRealData.h:34
virtual Int_t GetEntry(Long64_t entry=0, Int_t getall=0)
Read all leaves of entry and return total number of bytes read.
Definition: TBranch.cxx:1199
Bool_t CanIgnoreTObjectStreamer()
Definition: TClass.h:357
virtual const char * GetName() const
Returns name of object.
Definition: TNamed.h:51
The ROOT global object gROOT contains a list of all defined classes.
Definition: TClass.h:81
virtual void SetByteCount(UInt_t cntpos, Bool_t packInVersion=kFALSE)=0
virtual void Print(Option_t *option="") const
Print branch parameters.
virtual void SetLeafCount(TLeaf *leaf)
Set the leaf count of this leaf.
Definition: TLeaf.cxx:337
Long64_t entry
TTree * GetTree() const
Definition: TBranch.h:183
Int_t GetCompressionSettings() const
Definition: TFile.h:363
virtual void SetOffset(Int_t offset=0)
Definition: TLeaf.h:103
virtual void SetBasketSize(Int_t buffsize)
Set the basket size The function makes sure that the basket size is greater than fEntryOffsetlen.
Definition: TBranch.cxx:2096
tuple tree
Definition: tree.py:24
virtual Int_t GetSize() const
Definition: TCollection.h:95
#define ClassImp(name)
Definition: Rtypes.h:279
void Init(TTree *tree, TBranch *parent, const char *name, void *clonesaddress, Int_t basketsize=32000, Int_t compress=-1, Int_t splitlevel=1)
Initialization (non-virtual, to be called from constructor).
TClass * GetClass() const
Definition: TClonesArray.h:57
int type
Definition: TGX11.cxx:120
TTree * fTree
Definition: TBranch.h:94
void Browse(TBrowser *b)
Browse this collection (called by TBrowser).
TObjArray * GetListOfLeaves()
Definition: TBranch.h:178
virtual void Reset(Option_t *option="")
Reset branch.
TDirectory * fDirectory
Address of 1st leaf (variable or object)
Definition: TBranch.h:98
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:2801
#define name(a, b)
Definition: linkTestLib0.cpp:5
Int_t GetArrayDim() const
Return number of array dimensions.
virtual void SetMaximum(Int_t max)
Definition: TLeafI.h:55
An array of clone (identical) objects.
Definition: TClonesArray.h:32
A Branch for the case of an array of clone objects.
Definition: TBranchClones.h:31
virtual void ExpandCreateFast(Int_t n)
Expand or shrink the array to n elements and create the clone objects by calling their default ctor...
TClonesArray * fList
Definition: TBranchClones.h:34
virtual void Reset(Option_t *option="")
Reset a Branch.
Definition: TBranch.cxx:1924
Long64_t fReadEntry
Current basket number when reading.
Definition: TBranch.h:80
virtual void Browse(TBrowser *b)
Browse this branch.
TBranch * fMother
Pointer to Tree header.
Definition: TBranch.h:95
Bool_t IsBasic() const
Return true if data member is a basic type, e.g. char, int, long...
void Add(TObject *obj)
Definition: TObjArray.h:75
A TTree object has a header with a name and a title.
Definition: TTree.h:98
Int_t fEntryOffsetLen
Definition: TBranch.h:71
TDataMember * GetDataMember() const
Definition: TRealData.h:57
Int_t fN
flag = 1 if clonesarray has been read
Definition: TBranchClones.h:36
TObjArray fBranches
Definition: TBranch.h:88
TObject * At(Int_t idx) const
Definition: TObjArray.h:167
A TTree is a list of TBranches.
Definition: TBranch.h:58
Int_t fCompress
branch counter
Definition: TBranch.h:69
const Bool_t kTRUE
Definition: Rtypes.h:91
Long_t GetThisOffset() const
Definition: TRealData.h:59
virtual const char * GetName() const
Returns name of object.
Definition: TRealData.h:56
TString fFileName
Pointer to directory where this branch buffers are stored.
Definition: TBranch.h:99
TBranch * fParent
Pointer to top-level parent branch in the tree.
Definition: TBranch.h:96
virtual void ResetAfterMerge(TFileMergeInfo *)
Reset branch after a merge.
A TLeaf for an Integer data type.
Definition: TLeafI.h:29
Int_t fNdataMax
Number of elements in ClonesArray.
Definition: TBranchClones.h:37
virtual Version_t ReadVersion(UInt_t *start=0, UInt_t *bcnt=0, const TClass *cl=0)=0
char * fAddress
Pointer to parent branch.
Definition: TBranch.h:97
virtual void Warning(const char *method, const char *msgfmt,...) const
Issue warning message.
Definition: TObject.cxx:904