[ROOT] TTree::MakeClass and TTree::AddFriend

From: Sue Kasahara (schubert@hep.umn.edu)
Date: Tue Dec 30 2003 - 19:59:41 MET


Hi roottalk,
I am trying to use TTree::MakeClass with a set of friend trees:
{
TFile* file = new TFile("ntuple.root","READ");
TTree* treeA = (TTree*)(file -> Get("NtpA"));
TTree* treeB = (TTree*)(file -> Get("NtpB"));

treeA -> AddFriend(treeB);
treeA -> MakeClass();
}
I'm finding that the Class generated by MakeClass only
reflects the contents of treeA and not of its friend treeB.
Is there a way to set this up so that MakeClass will generate
a class with reference to both trees?  Otherwise, is it possible
to modify the MakeClass method to support this?
We have a set of users that find the MakeClass method useful,
and would like to make the use of friend trees with MakeClass
as transparent as possible.
I am using root version 3.10/01 updated 12/9/03 with gcc 3.2.2
on rh linux v9.
Thanks for your help,
-Sue K.



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