All filters declare a yp2_filter_struct - used for both static and
[metaproxy-moved-to-github.git] / src / filter_log.hpp
index c8d3f85..a829d80 100644 (file)
@@ -1,4 +1,4 @@
-/* $Id: filter_log.hpp,v 1.6 2005-10-25 11:48:30 adam Exp $
+/* $Id: filter_log.hpp,v 1.11 2006-01-04 11:19:04 adam Exp $
    Copyright (c) 2005, Index Data.
 
 %LICENSE%
@@ -7,29 +7,28 @@
 #ifndef FILTER_LOG_HPP
 #define FILTER_LOG_HPP
 
-#include <stdexcept>
-#include <vector>
+#include <boost/scoped_ptr.hpp>
 
 #include "filter.hpp"
 
-#include <boost/thread/mutex.hpp>
-
-
 namespace yp2 {
     namespace filter {
         class Log : public Base {
+            class Rep;
+            boost::scoped_ptr<Rep> m_p;
         public:
             Log();
+            Log(const std::string &x);
+            ~Log();
             void process(yp2::Package & package) const;
-            void set_prefix(const std::string &msg);
-        private:
-            /// static mutex to lock Ostream during logging operation
-            static boost::mutex m_log_mutex;
-            std::string m_msg;
         };
     }
 }
 
+extern "C" {
+    extern const struct yp2_filter_struct yp2_filter_log;
+}
+
 #endif
 /*
  * Local variables: