Re: operator root and brat- updated

From: Christian Holm Christensen (cholm@hehi03.nbi.dk)
Date: Thu Dec 07 2000 - 05:43:56 EST

  • Next message: Flemming Videbaek: "BrMagnetVolume"

    Hi Konstantin et al, 
    
    On Wed, 6 Dec 2000 19:35:02 -0500
    Konstantin Olchanski <olchansk@ux1.phy.bnl.gov> wrote
    concerning ": operator root and brat- updated":
    > 
    > The root, brat and friends in the operator account have been updated:
    > 
    > - root 2.25/3
    > - brat checked out from CVS current, builds cleanly
    > - SuperMon, builds cleanly
    > - brahvo, builds cleanly, installed in ~operator/bin.
    > 
    > Did I forget anything that needs to be rebuilt?
    
    I think you should also build bratroot for yours and others
    convenience. This is simply done by 
    
    	    make install 
    
    I've posted a message previously telling you all what bratroot is, but
    here goes again: 
    
    bratroot is a root-like (i.e., CINT based) application with all the
    BRAT libraries preloaded. Hence, no need for BratLoad.C ever never
    again. Also, there's a nice BRAHMS splash screen, and the prompt says
    "brat" - I think it's neat :-) 
    
    Has anyone tried to build BRAT using the new ROOT (`2.26/00' or pre3)? 
    
    As of ROOT 3, there'll be extensive support for schema evolution
    (Those who know about databases should be wetting themselves). This
    requires, that one uses the '+' option to the dictonary generator for
    any persistent object (some object that can be disk resident). Hence,
    I encourage everyone to use the following skeleton in thier LinkDef.h
    for persitent classes, shuch as data objects, calibration objects,
    etc. 
    
    	 #pragma link C++ class Br<Class Name>+;
    
    If your class has a custom Streamer method (I hope not), then you
    should probably rewrite it to look like 
    
      void Br<Class Name>::Streamer(TBuffer &R__b)
      {
         // Stream an object of class MyClass.
    
         if (R__b.IsReading()) {
           UInt_t R__s, R__c;
           Version_t R__v = R__b.ReadVersion(&R__s, &R__c);
           if (R__v > <Old Version>) {
              Br<Class Name>::Class()->ReadBuffer(R__b, this, R__v, R__s, R__c);
               return;
           }
           //====process old versions before automatic schema evolution
           <Old Streamer Read Body>  
         } 
         else 
           Br<Class Name>::Class()->WriteBuffer(R__b,this);
      }
    
    Where <old version> is the old version number in 
    ClassDef(Br<Class Name>,<version>) macro in your header file, and 
    <Old Streamer Read Body> is the reading part of the old streamer. 
    
    Please note, that this REQUIRES that you update the version number in
    ClassDef every time you reorder/add/remove the data members in your
    class! This is EXTREMLY important, and shouuld have been done in the
    first place. 
    
    Yours, 
    
    Christian  -----------------------------------------------------------
    Holm Christensen                             Phone:  (+45) 35 35 96 91 
      Sankt Hansgade 23, 1. th.                  Office: (+45) 353  25 305 
      DK-2200 Copenhagen N                       Web:    www.nbi.dk/~cholm    
      Denmark                                    Email:       cholm@nbi.dk
    



    This archive was generated by hypermail 2b29 : Thu Dec 07 2000 - 05:44:46 EST