Hi Tuan, I do not have enough information about your procedure. Are you aware that there is a class TChain to manage a list of files & trees ? Rene Brun On Wed, 20 Nov 2002, Vu Anh Tuan wrote: > Hi, > > I have a program that loops over a list of root trees. Each time when > the root file is changed, the code should be able to develop this change > and point to the new root tree. Here is the skeleton of myClass.cpp > > TTree* myClass::_myLocalTree = NULL; > // private variable TTree* _myLocalTree is declared static in > // myClass.hpp header > > myClass::myClass(TTree* rtree) > { > if (!_myLocalTree) _myLocalTree = rtree; > > if (_myLocalTree != rtree || _nflr == 0) { > _myLocalTree=rtree; > > // Do things here > } > > }//end of constructor > > Before encouting the first tree _myLocalTree is NULL, and then it points > to the first root tree. If now we remove this tree file, copy a new > one with the same name (but not the same tree) it should detect a > "new" one, in principle. > > And it doesn't work this way. Well, in fact, few months ago it worked, > but not now. > > So what's wrong with the code? > > Thanks, > > Tuan >
This archive was generated by hypermail 2b29 : Sat Jan 04 2003 - 23:51:20 MET