00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012 #ifndef ROOT_TVirtualPerfStats
00013 #define ROOT_TVirtualPerfStats
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025 #ifndef ROOT_TObject
00026 #include "TObject.h"
00027 #endif
00028
00029
00030 class TFile;
00031
00032
00033 class TVirtualPerfStats : public TObject {
00034
00035 public:
00036 virtual ~TVirtualPerfStats() {}
00037
00038 enum EEventType {
00039 kUnDefined,
00040 kPacket,
00041 kStart,
00042 kStop,
00043 kFile,
00044 kFileOpen,
00045 kFileRead,
00046 kRate,
00047 kNumEventType
00048 };
00049
00050 virtual void SimpleEvent(EEventType type) = 0;
00051
00052 virtual void PacketEvent(const char *slave, const char *slavename, const char *filename,
00053 Long64_t eventsprocessed, Double_t latency,
00054 Double_t proctime, Double_t cputime,
00055 Long64_t bytesRead) = 0;
00056
00057 virtual void FileEvent(const char *slave, const char *slavename, const char *nodename,
00058 const char *filename, Bool_t isStart) = 0;
00059
00060 virtual void FileOpenEvent(TFile *file, const char *filename, Double_t start) = 0;
00061
00062 virtual void FileReadEvent(TFile *file, Int_t len, Double_t start) = 0;
00063
00064 virtual void RateEvent(Double_t proctime, Double_t deltatime,
00065 Long64_t eventsprocessed, Long64_t bytesRead) = 0;
00066
00067 virtual void SetBytesRead(Long64_t num) = 0;
00068 virtual Long64_t GetBytesRead() const = 0;
00069 virtual void SetNumEvents(Long64_t num) = 0;
00070 virtual Long64_t GetNumEvents() const = 0;
00071
00072 static const char *EventType(EEventType type);
00073
00074 ClassDef(TVirtualPerfStats,0)
00075 };
00076
00077
00078 R__EXTERN TVirtualPerfStats *gPerfStats;
00079
00080
00081 #endif