Dear all,
I save a class “Event” in a TTree. I have another class “Vertex”, inheriting from “Event”. It contains a functionVertex::Reconstruct()
to use protected data members in “Event” to reconstruct the event vertex, and save it in a TVector3 data member. Would the following codes work?
Vertex *vtx = new Vertex;
tree->SetBranchAddress("event",&vtx);
for (UInt_t i=0; i<tree->GetEntries(); i++) {
tree->GetEntry(i);
vtx->Reconstruct();
}
Thanks,
Jing