X-Git-Url: http://git.uio.no/git/?a=blobdiff_plain;f=STEER%2FAliRunLoader.h;h=fce21170414d8da18cefaf7f8dfb2658033c843a;hb=1fbe12d44cebdec4a562e9a8d39b82789c657c0f;hp=93ed898ee566c250c05ddd5d31f84cb1488d4233;hpb=bacbe0fdbdcdafc29ed6025ba1e65802e848e2e6;p=u%2Fmrichter%2FAliRoot.git diff --git a/STEER/AliRunLoader.h b/STEER/AliRunLoader.h index 93ed898ee56..fce21170414 100644 --- a/STEER/AliRunLoader.h +++ b/STEER/AliRunLoader.h @@ -53,9 +53,6 @@ class AliRunLoader: public TNamed AliRunLoader(); AliRunLoader(const char* topfoldername); AliRunLoader(TFolder* topfolder); - AliRunLoader(const AliRunLoader &rl); - AliRunLoader & operator = (const AliRunLoader &rl) - {rl.Copy(*this); return *this;} virtual ~AliRunLoader(); @@ -105,8 +102,9 @@ class AliRunLoader: public TNamed TTree* TreeTR() const; //returns the tree from folder; shortcut method AliRun* GetAliRun()const; + Int_t GetRunNumber() const {return fRun;} + void SetRunNumber(Int_t run) {fRun=run;} - Int_t WriteGeometry(Option_t* opt=""); Int_t WriteHeader(Option_t* opt=""); Int_t WriteTrigger(Option_t* opt=""); Int_t WriteAliRun(Option_t* opt=""); @@ -120,12 +118,12 @@ class AliRunLoader: public TNamed Int_t WriteRecPoints(Option_t* opt=""); Int_t WriteTracks(Option_t* opt=""); - Int_t LoadHits(Option_t* detectors = "all",Option_t* opt = "RAED"); - Int_t LoadSDigits(Option_t* detectors = "all",Option_t* opt = "RAED"); - Int_t LoadDigits(Option_t* detectors = "all",Option_t* opt = "RAED"); - Int_t LoadRecPoints(Option_t* detectors = "all",Option_t* opt = "RAED"); - Int_t LoadTracks(Option_t* detectors = "all",Option_t* opt = "RAED"); - Int_t LoadRecParticles(Option_t* detectors = "all",Option_t* opt = "RAED"); + Int_t LoadHits(Option_t* detectors = "all",Option_t* opt = "READ"); + Int_t LoadSDigits(Option_t* detectors = "all",Option_t* opt = "READ"); + Int_t LoadDigits(Option_t* detectors = "all",Option_t* opt = "READ"); + Int_t LoadRecPoints(Option_t* detectors = "all",Option_t* opt = "READ"); + Int_t LoadTracks(Option_t* detectors = "all",Option_t* opt = "READ"); + Int_t LoadRecParticles(Option_t* detectors = "all",Option_t* opt = "READ"); void UnloadHits(Option_t* detectors = "all"); void UnloadSDigits(Option_t* detectors = "all"); @@ -157,7 +155,8 @@ class AliRunLoader: public TNamed void SetDirName(TString& dirname); Int_t GetFileOffset() const; void SetNumberOfEventsPerFile(Int_t nevpf){fNEventsPerFile = nevpf;} - + void SetNumberOfEventsPerRun(Int_t nevpr) {fNEventsPerRun = nevpr;} + Int_t GetNumberOfEventsPerRun() {return fNEventsPerRun;} void SetDigitsFileNameSuffix(const TString& suffix);//adds the suffix before ".root", //e.g. TPC.Digits.root -> TPC.DigitsMerged.root //made on Jiri Chudoba demand @@ -178,7 +177,7 @@ class AliRunLoader: public TNamed /***** Public S T A T I C Stuff *******/ /******************************************/ static AliRunLoader* GetRunLoader(const char* eventfoldername); - static AliRunLoader* GetRunLoader(){return fgRunLoader;} + static AliRunLoader* Instance(){return fgRunLoader;} static AliLoader* GetDetectorLoader(const char* detname, const char* eventfoldername); static TTree* GetTreeH(const char* detname, Bool_t maketree, const char* eventfoldername); static TTree* GetTreeS(const char* detname, Bool_t maketree, const char* eventfoldername); @@ -187,7 +186,6 @@ class AliRunLoader: public TNamed static TTree* GetTreeT(const char* detname, Bool_t maketree, const char* eventfoldername); static TTree* GetTreeP(const char* detname, Bool_t maketree, const char* eventfoldername); -// static AliRunDigitizer* GetRunDigitizer(); // Tasks are supposed to be singletons, that is why following methods are static static TTask* GetRunDigitizer(); // static TTask* GetRunSDigitizer(); // @@ -208,58 +206,47 @@ class AliRunLoader: public TNamed static TString GetGAliceName () {return fgkGAliceName;} protected: - /**********************************************/ - /************ PROTECTED ***************/ - /********* D A T A ************/ - /**********************************************/ + void SetGAliceFile(TFile* gafile);//sets the pointer to gAlice file + Int_t OpenKineFile(Option_t* opt); + Int_t OpenTrackRefsFile(Option_t* opt); + + Int_t OpenDataFile(const TString& filename,TFile*& file,TDirectory*& dir,Option_t* opt,Int_t cl); + void SetUnixDir(const TString& udirname); + const TString SetFileOffset(const TString& fname);//adds the proper number before .root + void SetDetectorAddresses(); - TObjArray *fLoaders; // List of Detectors - TFolder *fEventFolder; //!top folder for this run + TObjArray *fLoaders; // List of Detectors + TFolder *fEventFolder; //!top folder for this run - Int_t fCurrentEvent;//!Number of current event + Int_t fRun; //! Current run number + Int_t fCurrentEvent;//!Number of current event TFile *fGAFile;//! pointer to main file with AliRun and Run Loader -> galice.root AliHeader *fHeader;//! pointer to header AliStack *fStack; //! pointer to stack AliCentralTrigger *fCTrigger; //! pointer to CEntral Trigger Processor - AliDataLoader *fKineDataLoader;// kinematics data loader - AliDataLoader *fTrackRefsDataLoader;//track reference data loader + AliDataLoader *fKineDataLoader;// kinematics data loader + AliDataLoader *fTrackRefsDataLoader;//track reference data loader - Int_t fNEventsPerFile; //defines number of events stored per one file - TString fUnixDirName; //! name of unix path to directory that contains event + Int_t fNEventsPerFile; //defines number of events stored per one file + Int_t fNEventsPerRun; //defines number of event per run + TString fUnixDirName; //! name of unix path to directory that contains event static const TString fgkDefaultKineFileName;//default file name with kinamatics static const TString fgkDefaultTrackRefsFileName;//default file name with kinamatics static const TString fgkDefaultTriggerFileName;//default file name with trigger - - /*********************************************/ - /************ PROTECTED **************/ - /********* M E T H O D S ***********/ - /*********************************************/ - - void SetGAliceFile(TFile* gafile);//sets the pointer to gAlice file - Int_t OpenKineFile(Option_t* opt); - Int_t OpenTrackRefsFile(Option_t* opt); - - Int_t OpenDataFile(const TString& filename,TFile*& file,TDirectory*& dir,Option_t* opt,Int_t cl); - void SetUnixDir(const TString& udirname); - const TString SetFileOffset(const TString& fname);//adds the proper number before .root - void SetDetectorAddresses(); private: + AliRunLoader(const AliRunLoader &r); //Not implemented + AliRunLoader & operator = (const AliRunLoader &); //Not implemented void GetListOfDetectors(const char * namelist,TObjArray& pointerarray) const; - void CleanHeader(){Clean(fgkHeaderContainerName);} void CleanTrigger(){Clean(fgkTriggerContainerName);} void Clean(const TString& name); - Int_t SetEvent(); - static AliRunLoader* fgRunLoader; //pointer to the AliRunLoader instance - -private: - void Copy(TObject &arun) const; + static AliRunLoader* fgRunLoader; //pointer to the AliRunLoader instance static const TString fgkRunLoaderName; //default name of the run loader static const TString fgkHeaderContainerName; //default name of the kinematics container (TREE) name - TreeE @@ -271,7 +258,7 @@ private: static const TString fgkKineBranchName; //default name of the branch with kinematics static const TString fgkGAliceName; //default name for gAlice file - ClassDef(AliRunLoader,2) + ClassDef(AliRunLoader,3) }; #endif