Re: [ROOT] Writeing to a file

From: Rene Brun (Rene.Brun@cern.ch)
Date: Tue Apr 08 2003 - 13:08:59 MEST


Hi Thomas,

See class TRef at:

http://root.cern.ch/root/htmldoc/TRef.html

Rene Brun

Thomas Bretz wrote:
> 
> Hi all,
> 
> assuming I have a class A
> class A : public TObject
> {
>     int somedata;
>     ClassDef(A, 1)
> }
> ans a class B referencing class A
> class B : public TObject
> {
>     A *a;
>     ClassDef(B, 1)
> }
> 
> Now I write class B to a file (TBranch::Fill). Assuming, that the
> pointer to A references a different instance of A each tenth event of B
> I write to a file and I write B 100 times.
> How many objects of A are written? 100 or 10?
> 
> Thanks,
> Thomas.



This archive was generated by hypermail 2b29 : Thu Jan 01 2004 - 17:50:10 MET