From af7e1a1ca8b36064593becf62b1a91468ad32237 Mon Sep 17 00:00:00 2001 From: w00t Date: Sat, 9 Feb 2008 12:41:17 +0000 Subject: New logging implementation. Also write messages about InspIRCd::Log() being deprecated. Any takers on changing it all to use the new system? :P. STILL TODO: create blocks in config, add a method called to 'cleanup' (or use destructor) of logstreams, add a method to logmanager to initiate destruction of all logstreams. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8858 e03df62e-2008-0410-955e-edbf42e46eb7 --- include/filelogger.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'include/filelogger.h') diff --git a/include/filelogger.h b/include/filelogger.h index 77ca6f886..8395f1c96 100644 --- a/include/filelogger.h +++ b/include/filelogger.h @@ -88,5 +88,17 @@ class CoreExport FileLogger : public EventHandler virtual ~FileLogger(); }; +class CoreExport FileLogStream : public LogStream +{ + private: + FileLogger *f; + public: + FileLogStream(InspIRCd *Instance, FILE *f, const std::string &type) : LogStream(Instance, type) + { + this->f = new FileLogger(Instance, f); + } + + virtual void OnLog(int loglevel, const std::string &msg); +}; #endif -- cgit v1.2.3