Re: Changing branch name ...

From: Victor Perevoztchikov (perev@bnl.gov)
Date: Wed Mar 15 2000 - 17:53:36 MET


> > Hi Anton,
> > Currently, you cannot and should not change the name of a branch in a
> > tree.
> > SetName should be redefined in TBranch and derivatives.
> >
Due to the old name is written to the file, changing the name required:
 1. rewriting the file
 2. or defining aliases, which provided map between old and new name.

I think both ways are the source of mess and it is better to leave as it is now.
user must think before, not after.

Victor.



"Pasha Murat (630)840-8237 FNAL (630)859-3463 home" wrote:
> 
> Rene Brun wrote:
> >
> > Hi Anton,
> > Currently, you cannot and should not change the name of a branch in a
> > tree.
> > SetName should be redefined in TBranch and derivatives.
> >
> 
> I think that the possibility to change a name of a file associated with a
> given branch would be very useful in the context of a full-scale
> data handling system. Let's assume a ROOT tree which branches can reside on
> different media, such that some of them would be disk-resident and the others
> would be staged to tape. Then the header of such tree (always disk-resident!)
> would have special names for these branches, for example:
> 
>                         /stage:migrated_branch_1.root
> 
> making it possible to read in the tree header, loop over all the
> branches and to send a request to the data handling system to
> spool the files for tape-resident ones back to disk (if their processing
> was requested).
> The last step of this procedure would be to redefine the
> file names for these branches IN MEMORY (NOT IN DISK-RESIDENT tree header)
> to point to the spool area after which the analysis / production job could
> start.
>                                                 best, pasha

-- 
Victor M. Perevoztchikov   perev@bnl.gov  perev@vxcern.cern.ch       
Brookhaven National Laboratory MS 510A PO Box 5000 Upton NY 11973-5000
tel office : 631-344-7894; fax 631-344-4206; home 631-345-2690



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