SetBranchAddress question

From: Anton Fokin (fokin@tsl.uu.se)
Date: Sat Feb 26 2000 - 14:57:55 MET


Hi!

could you tell me why you are using &event when calling

void SetBranchAddress(const char *bname, void *add)

   Event *event = new Event();
   T->SetBranchAddress("event", &event);


it looks like you are setting address of pointer to the branch instead of
address of branch (or address of pointer to the object from where read/write
data?). Is it something with terminology? When I looked at this function for
the very first time, I wanted to do

Event event;
T->SetBranchAddress("event", &event);

I remember I've seen some related comments in one of the root
tutorials/examples but I am not able to find it now. Hmmm... where is our
nice documentation about root i/o? :)

Best,
Anton



This archive was generated by hypermail 2b29 : Tue Jan 02 2001 - 11:50:20 MET