Hi! It's not exactly that i wouldn't like it Streamed ... i just wouldn't like it to be Streamed twice. So that mBar would still be pointing to the same Bar when Ev is initialised from the TTree with TBranch::GetEvent(). I know that in case of files each object is written out only once ... regardless of the number of pointers to it. I just assumed it is the same with trees. I guess i'll use int index and a method to extract pointer from Collection if my assumption was wrong. Thanx anyway ... Cheers, matevz On Mon, 15 Feb 1999, Otto Schaile wrote: > Hi Matevz, > to avoid that the object pointed to by mBar is streamed out, > you shoud add a comment starting with //! > > Bar *mBar; //! dont stream the object pointed to by *mBar > Cheers > Otto > > ------------------------- > > > On Mon, 15 Feb 1999, Matevz Tadel wrote: > > > Hi ... > > > > I have a case like: > > > > class Ev:public TObject{ > > TOrdCollection *mFoo; // Collection of Bar objects > > Bar *mBar; // Points to one of the Bars in mFoo > > }; > > > > > > When writing Ev to a tree, Bar that is pointed to by mBar gets written > > twice. Have I done sth wrong or is it a feature? > > > > Cheers, > > matevz > > > > _____________________________________________________________ > > Matevz Tadel, E-mail: Matevz.Tadel@ijs.si > > Department of Experimental High Energy Physics - F9 > > Jozef Stefan Institute, Jamova 39, P.o.Box 3000 > > SI-1001 Ljubljana, Slovenia > > Tel.: +386-61-177-3674 Fax: +386-61-125-7074 > > ------------------------------------------------------------- > > > > ---------------------------------------------------------------------------- > Otto Schaile Sektion Physik der LMU Muenchen > Phone: (+49 89)289 14070 Am Coulombwall 1, D-85748 Garching, Germany > FAX: (+49 89)289 14072 EMail: Otto.Schaile@Physik.Uni-Muenchen.DE > >
This archive was generated by hypermail 2b29 : Tue Jan 04 2000 - 00:43:29 MET