Go to the documentation of this file.00001 #include "GaudiKernel/Auditor.h"
00002
00005 class CommonAuditor: public Auditor {
00006 public:
00010 CommonAuditor(const std::string& name, ISvcLocator *svcloc);
00012 virtual ~CommonAuditor();
00013
00017
00018 virtual void before(StandardEventType evt, const std::string& caller);
00019 virtual void before(StandardEventType evt, INamedInterface* caller);
00020 virtual void before(CustomEventTypeRef evt, const std::string& caller);
00021 virtual void before(CustomEventTypeRef evt, INamedInterface* caller);
00023
00027
00028 virtual void after(StandardEventType evt, const std::string& caller, const StatusCode& sc);
00029 virtual void after(StandardEventType evt, INamedInterface* caller, const StatusCode& sc);
00030 virtual void after(CustomEventTypeRef evt, const std::string& caller, const StatusCode& sc);
00031 virtual void after(CustomEventTypeRef evt, INamedInterface* caller, const StatusCode& sc);
00033
00034 protected:
00035
00037 virtual void i_before(CustomEventTypeRef evt, const std::string& caller) = 0;
00039 virtual void i_after(CustomEventTypeRef evt, const std::string& caller, const StatusCode& sc) = 0;
00040
00042 inline bool i_auditEventType(const std::string& evt) {
00043
00044
00045 const std::vector<std::string> &v = m_types.value();
00046
00047
00048 return (v.size() == 0) || (
00049 (v[0] != "none") &&
00050 (find(v.begin(), v.end(), evt) != v.end())
00051 );
00052 }
00053
00054 StringArrayProperty m_types;
00055
00057 void i_updateCustomTypes(Property &);
00058 StringArrayProperty m_customTypes;
00059 };