libmoost
/home/mhx/git/github/libmoost/include/moost/signal/signal_handler.h
Go to the documentation of this file.
00001 /* vim:set ts=3 sw=3 sts=3 et: */
00028 #ifndef MOOST_SIGNAL_SIGNAL_HANDLER_H__
00029 #define MOOST_SIGNAL_SIGNAL_HANDLER_H__
00030 
00031 #include <csignal>
00032 
00033 #include <boost/shared_ptr.hpp>
00034 #include <boost/function.hpp>
00035 #include <boost/noncopyable.hpp>
00036 
00037 namespace moost { namespace signal {
00038 
00042 class signal_handler : public boost::noncopyable
00043 {
00044 private:
00045 
00046   class impl;
00047 
00048   boost::shared_ptr<impl> m_pimpl;
00049 
00050 public:
00051 
00057   signal_handler(const boost::function<void(int)> & callback);
00058 
00059 };
00060 
00061 }} // moost::signal
00062 
00063 #endif // MOOST_SIGNAL_SIGNAL_HANDLER_H__