Răsfoiți Sursa

Epoller add Register member function

tanghai 15 ani în urmă
părinte
comite
acdf55ef09
1 a modificat fișierele cu 7 adăugiri și 3 ștergeri
  1. 7 3
      src/net/epoller.h

+ 7 - 3
src/net/epoller.h

@@ -4,12 +4,16 @@
 #include <boost/unordered_map.hpp>
 
 namespace hainan {
-typedef boost::unordered_map< int, boost::function<void (void)> > HandlerMap;
-class Epoller: private boost::noncopyable
+
+using namespace boost;
+typedef unordered_map< int, function<void (void)> > HandlerMap;
+
+class Epoller: private noncopyable
 {
 private:
 	HandlerMap handlers;
 public:
-	void Add()
+	void Register();
+	void Add();
 };
 } // hainan