1 #ifndef ALIMUONLOGGER_H
2 #define ALIMUONLOGGER_H
4 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5 * See cxx source for full Copyright notice */
10 /// \class AliMUONLogger
11 /// \brief A logger that keeps track of the number of times a message appeared
13 // Author Laurent Aphecetche
15 #include <Riostream.h>
25 class AliMUONStringIntMap;
29 class AliMUONLogger : public TObject
32 AliMUONLogger(Int_t maxNumberOfEntries=-1);
33 virtual ~AliMUONLogger();
35 Int_t Log(const char* message);
37 void Print(Option_t* opt="") const;
39 void Print(TString& key, ofstream& out) const;
41 void Clear(Option_t* /*option*/ ="");
43 Bool_t Next(TString& msg, Int_t& occurance);
47 Int_t NumberOfEntries() const;
51 AliMUONLogger(const AliMUONLogger& rhs); // not implemented
53 AliMUONLogger& operator=(const AliMUONLogger& rhs); // not implemented
57 Int_t fMaxNumberOfEntries; //!< after this number, print and reset
58 AliMUONStringIntMap* fLog; //!< map from message to number of times the message was issued
60 ClassDef(AliMUONLogger,1) // A logger that keeps track of the number of times a message appeared