Utils/Console: Fix singleton instantiation order (ServerManager / Scheduler)
[senf.git] / PPI / IOEvent.hh
index 5a3e188..77c5d26 100644 (file)
@@ -29,6 +29,7 @@
 // Custom includes
 #include "../Scheduler/Scheduler.hh"
 #include "Events.hh"
+#include "../Utils/Exception.hh"
 
 //#include "IOEvent.mpp"
 ///////////////////////////////hh.p////////////////////////////////////////
@@ -94,14 +95,12 @@ namespace ppi {
         ///////////////////////////////////////////////////////////////////////////
 
         /** \brief Unhandled error condition */
-        struct ErrorException : public std::exception
-        { virtual char const * what() const throw() 
-                { return "senf::ppi::IOEvent::ErrorException"; } };
+        struct ErrorException : public senf::Exception
+        { ErrorException() : senf::Exception("senf::ppi::IOEvent::ErrorException"){} };
 
         /** \brief Unhandled hangup condition */
-        struct HangupException : public std::exception
-        { virtual char const * what() const throw() 
-                { return "senf::ppi::IOEvent::HangupException"; } };
+        struct HangupException : public senf::Exception
+        { HangupException() : senf::Exception("senf::ppi::IOEvent::HangupException"){} };
 
     protected:
 
@@ -109,7 +108,7 @@ namespace ppi {
         virtual void v_enable();
          virtual void v_disable();
         
-        void cb(Scheduler::EventId event);
+        void cb(int event);
 
         int fd_;
         unsigned events_;