BRAT 2.4.5
Class index
Full class index
brahmlib
BRAHMS
ROOT page

BrCalibrationManager


class description - source file - inheritance tree

class BrCalibrationManager : public TObject

    private:
BrDbElement* GetDbElement(const Char_t* classname, const Char_t* detector) protected:
BrCalibrationManager BrCalibrationManager() public:
BrCalibrationManager BrCalibrationManager(BrCalibrationManager&) virtual void ~BrCalibrationManager() static TClass* Class() void Commit(Int_t, Int_t) Int_t DebugLevel() const void Init() static BrCalibrationManager* Instance() virtual TClass* IsA() const virtual void Print(Option_t* option = "L") const BrCalibration* Register(const Char_t* classname, const Char_t* detector) void SetDebugLevel(Int_t level) virtual void ShowMembers(TMemberInspector& insp, char* parent) virtual void Streamer(TBuffer& b) void StreamerNVirtual(TBuffer& b) void Update() void Update(Int_t, Int_t)

Data Members

    private:
TObjArray* fObjectlist List BrCalibrationManager::DbStatus_t fState State of file Int_t fDebugLevel static BrCalibrationManager* fInstance public:
static const BrCalibrationManager::DbStatus_t INIT static const BrCalibrationManager::DbStatus_t OPEN static const BrCalibrationManager::DbStatus_t DEFAULT_PARAMETER_SET

Class Description

  BrCalibrationManager

  This manager class will be the owner of the DetectorParameter
  Objects. Its intended use if for a user module to access database
  only via this mechanism, and not by opening any files by
  themselves. It also ensures that  in the case that several user
  modules uses a given geometry it is ensured that
  a) The refer to the same object
  b) The application can use the setter methods to change values for a
     geometry constant and will thus be the same for all modules.
  c) The objects are owned by the manager and will be deleted only
     when the program exists (The instance is a static object).

  Sample code:

  The application can load the Manager and keep a global pointer
  accesible via a Brat common application file. It is in fact
  implemented via a Singleton mechanism. This enables us to use both
  the global mechanism as well as the instantons.

  Main application will have
  ---------------------------
  BrCalibrationManager *gParamDb =
    BrCalibrationManager::Instance();


  The user module should have (either in the Named Constructor
  or in the Init() method.
  ------------------------------------
  BrCalibrationManager *gParamDb =
    BrCalibrationManager::Instance();

_______________________________________________________________________

 BrDbElement

 This class is used only by the manager class.
 The objects are used to maintain what databases objects has been
 loaded via this mechanism.


BrCalibrationManager()

BrCalibrationManager* Instance()

~BrCalibrationManager()

BrCalibration* Register(const Char_t* classname, const Char_t* detector)
 Return a pointer to the concrete class.
 This is the only place where specific references to concrete class
 are given. But in order to avoid cyclic dependencies, references
 are made indirectly through the G__CallFunc interface.  That also
 makes this routine much more general.  It should not have to be
 modified whenever a new parameter class is added.  The only thing
 one has to take care of is that the parameter class inherits from
 TObject, or better yet (I think) TNamed.  They must also have a
 constructor with 3 arguments that are Char_t *'s, eg
   BrDetectorParamsTof::BrDetectorParamsTof(Char_t *name,
                                            Char_t *title,
                                            Char_t *filename)

BrDbElement* GetDbElement(const Char_t* classname, const Char_t* detector)
  Find a geometry database member with the requested detector and
  in the  given class.


void Print(Option_t* option) const
 Print information on the manager to std out.
 Options
    S           Status
    L           List of BrCalibrations manged by this manager

void Init()
 Call the Init method for all of the ParameterObjects that has been
 registered.


void Update(Int_t start, Int_t stop)
 Call the Update method for all of the ParameterObjects that has
 been registered.


void Commit(Int_t start, Int_t stop)
 Call the Commit method for all of the ParameterObjects that has
 been registered.




Inline Functions


                        void Update(Int_t, Int_t)
                       Int_t DebugLevel() const
                        void SetDebugLevel(Int_t level)
                     TClass* Class()
                     TClass* IsA() const
                        void ShowMembers(TMemberInspector& insp, char* parent)
                        void Streamer(TBuffer& b)
                        void StreamerNVirtual(TBuffer& b)
        BrCalibrationManager BrCalibrationManager(BrCalibrationManager&)

This page automatically generated by script docBrat by Christian Holm

Copyright ; 2002 BRAHMS Collaboration <brahmlib@rcf.rhic.bnl.gov>
Last Update on 2002/03/21 23:41:37 $ by cholm $

Validate HTML
Validate CSS