- AliRawEvent(const AliRawEvent &); // not implemented, usage causes
- void operator=(const AliRawEvent &); // link time error
-
- ClassDef(AliRawEvent,1) // ALICE raw event object
-};
-
-
-class AliStats : public TObject {
-
-public:
- AliStats(const char *filename = "", Int_t compmode = 0, Bool_t filter = kFALSE);
- virtual ~AliStats();
- AliStats &operator=(const AliStats &rhs);
-
- void SetEvents(Int_t events) { fEvents = events; }
- void SetFirstId(Int_t run, Int_t event) { fFirstRun = run; fFirstEvent = event; }
- void SetLastId(Int_t run, Int_t event) { fLastRun = run; fLastEvent = event; }
- void SetBeginTime() { fBegin.Set(); }
- void SetEndTime() { fEnd.Set(); }
- void SetFileSize(Double_t size) { fFileSize = size; }
- void SetCompressionFactor(Float_t comp) { fCompFactor = comp; }
- void Fill(Float_t time);
- void WriteToDB(AliRawDB *rawdb);
-
- Int_t GetEvents() const { return fEvents; }
- Int_t GetFirstRun() const { return fFirstRun; }
- Int_t GetFirstEvent() const { return fFirstEvent; }
- Int_t GetLastRun() const { return fLastRun; }
- Int_t GetLastEvent() const { return fLastEvent; }
- TDatime &GetBeginTime() { return fBegin; }
- TDatime &GetEndTime() { return fEnd; }
- Double_t GetFileSize() const { return fFileSize; }
- Int_t GetCompressionMode() const { return fCompMode; }
- Float_t GetCompressionFactor() const { return fCompFactor; }
- Bool_t GetFilterState() const { return fFilter; }
- const char *GetFileName() const { return fFileName; }
- TH1F *GetRTHist() const { return fRTHist; }
-
-private:
- Int_t fEvents; // number of events in this file
- Int_t fFirstRun; // run number of first event in file
- Int_t fFirstEvent; // event number of first event in file
- Int_t fLastRun; // run number of last event in file
- Int_t fLastEvent; // event number of last event in file
- TDatime fBegin; // begin of filling time
- TDatime fEnd; // end of filling time
- TString fFileName; // name of file containing this data
- Double_t fFileSize; // size of file
- Float_t fCompFactor; // tree compression factor
- Int_t fCompMode; // compression mode
- Bool_t fFilter; // 3rd level filter on/off
- TH1F *fRTHist; // histogram of real-time to process chunck of data
- Float_t fChunk; //!chunk to be histogrammed
-
- AliStats(const AliStats &); // not implemented
-
- ClassDef(AliStats,1) // Statistics object
-};
-
-
-class AliRawDB : public TObject {
-
-public:
- AliRawDB(AliRawEvent *event, Double_t maxsize, Int_t compress,
- Bool_t create = kTRUE);
- virtual ~AliRawDB() { Close(); }
-
- virtual const char *GetOpenOption() const { return "RECREATE"; }
- virtual Int_t GetNetopt() const { return 0; }
- virtual Bool_t Create();
- virtual void Close();
- void Fill() { fTree->Fill(); }
- Bool_t FileFull() { return (fRawDB->GetBytesWritten() > fMaxSize) ?
- kTRUE : kFALSE; }
-
- Bool_t NextFile();
-
- Double_t GetBytesWritten() const { return fRawDB->GetBytesWritten(); }
- TFile *GetDB() const { return fRawDB; }
- const char *GetDBName() const { return fRawDB->GetName(); }
- Int_t GetEvents() const { return (Int_t) fTree->GetEntries(); }
- AliRawEvent *GetEvent() const { return fEvent; }
- Float_t GetCompressionFactor() const;
- Int_t GetCompressionMode() const { return fRawDB->GetCompressionLevel(); }
-
-protected:
- TFile *fRawDB; // DB to store raw data
- TTree *fTree; // tree used to store raw data
- AliRawEvent *fEvent; // AliRawEvent via which data is stored
- Int_t fCompress; // compression mode (1 default)
- Double_t fMaxSize; // maximum size in bytes of the raw DB
-
- virtual const char *GetFileName() const;
- virtual Bool_t FSHasSpace(const char *fs) const;
- virtual void MakeTree();
-
-private:
- AliRawDB(const AliRawDB &); // not implemented, usage causes
- void operator=(const AliRawDB &); // link time error
-
- ClassDef(AliRawDB,0) // Raw DB
-};
-
-
-class AliRawRFIODB : public AliRawDB {
-
-public:
- AliRawRFIODB(AliRawEvent *event, Double_t maxsize, Int_t compress);
- ~AliRawRFIODB() { Close(); }
-
- void Close();
-
-private:
- const char *GetFileName() const;
-
- ClassDef(AliRawRFIODB,0) // Raw DB via RFIO
-};
-
-
-class AliRawCastorDB : public AliRawDB {
-
-public:
- AliRawCastorDB(AliRawEvent *event, Double_t maxsize, Int_t compress);
- ~AliRawCastorDB() { Close(); }
-
- const char *GetOpenOption() const { return "-RECREATE"; }
- Int_t GetNetopt() const { return 0; }
- void Close();
-
-private:
- const char *GetFileName() const;
-
- ClassDef(AliRawCastorDB,0) // Raw DB via CASTOR and rootd
-};
-
-
-class AliRawRootdDB : public AliRawDB {
-
-public:
- AliRawRootdDB(AliRawEvent *event, Double_t maxsize, Int_t compress);
- ~AliRawRootdDB() { Close(); }
-
- void Close();
-
-private:
- const char *GetFileName() const;
-
- ClassDef(AliRawRootdDB,0) // Raw DB via rootd
-};
-
-
-class AliRawNullDB : public AliRawDB {
-
-public:
- AliRawNullDB(AliRawEvent *event, Double_t maxsize, Int_t compress);
- ~AliRawNullDB() { Close(); }
-
- void Close();
-
-private:
- const char *GetFileName() const;
-
- ClassDef(AliRawNullDB,0) // Raw DB to /dev/null
-};
-
-
-class AliTagDB : public TObject {
-
-public:
- AliTagDB(AliRawEventHeader *header, Double_t maxsize, Bool_t create = kTRUE);
- virtual ~AliTagDB() { Close(); }
-
- Bool_t Create();
- virtual void Close();
- void Fill() { fTree->Fill(); }
- Bool_t FileFull()
- { return (fTagDB->GetBytesWritten() > fMaxSize) ? kTRUE : kFALSE; }
-
- Bool_t NextFile();
-
- Double_t GetBytesWritten() const { return fTagDB->GetBytesWritten(); }
- TFile *GetDB() const { return fTagDB; }
- const char *GetDBName() const { return fTagDB->GetName(); }
- AliRawEventHeader *GetHeader() const { return fHeader; }
- Int_t GetEvents() const { return (Int_t) fTree->GetEntries(); }
- Float_t GetCompressionFactor() const;
-
-protected:
- TFile *fTagDB; // DB to store header information only (tag)
- TTree *fTree; // tree use to store header
- AliRawEventHeader *fHeader; // header via which data is stored
- Double_t fMaxSize; // maximum size in bytes of tag DB