]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - include/socketengines/socketengine_iocp.h
Sort the module list to give a useful indicator of compile progress
[user/henk/code/inspircd.git] / include / socketengines / socketengine_iocp.h
index 95aa029d8f56e388c28a06e9b5852ae92604c147..0f4f6bdf524bfd61f4eaf891fb54a178beef6b97 100644 (file)
@@ -3,7 +3,7 @@
  *       +------------------------------------+
  *
  *  InspIRCd: (C) 2002-2009 InspIRCd Development Team
- * See: http://www.inspircd.org/wiki/index.php/Credits
+ * See: http://wiki.inspircd.org/Credits
  *
  * This program is free but copyrighted software; see
  *         the file COPYING for details.
@@ -103,12 +103,12 @@ class IOCPEngine : public SocketEngine
                }
                return -1;
        }
-       
+
        /** Global I/O completion port that sockets attach to.
         */
        HANDLE m_completionPort;
 
-       /** This is kinda shitty... :/ for getting an address from a real fd. 
+       /** This is kinda shitty... :/ for getting an address from a real fd.
         */
        std::map<int, EventHandler*> m_binding;
 
@@ -121,7 +121,7 @@ public:
        /** Creates an IOCP Socket Engine
         * @param Instance The creator of this object
         */
-       IOCPEngine(InspIRCd* Instance);
+       IOCPEngine();
 
        /** Deletes an IOCP socket engine and all the attached sockets
         */
@@ -131,7 +131,7 @@ public:
         * @param eh EventHandler to add
         * @return True if success, false if no room
         */
-       bool AddFd(EventHandler* eh);
+       bool AddFd(EventHandler* eh, int event_mask);
 
        /** Gets the maximum number of file descriptors that this engine can handle.
         * @return The number of file descriptors
@@ -144,7 +144,7 @@ public:
        __inline int GetRemainingFds()
        {
                register int count = 0;
-               register int i = 0;                     
+               register int i = 0;
                for(; i < MAX_DESCRIPTORS; ++i)
                        if(ref[i] == 0)
                                ++count;
@@ -166,10 +166,7 @@ public:
         */
        std::string GetName();
 
-       /** Queues a Write event on the specified event handler.
-        * @param eh EventHandler that needs data sent on
-        */
-       void WantWrite(EventHandler* eh);
+       void OnSetEvent(EventHandler* eh, int old_mask, int new_mask);
 
        /** Posts a completion event on the specified socket.
         * @param eh EventHandler for message
@@ -234,8 +231,7 @@ class SocketEngineFactory
 public:
        /** Create a new instance of SocketEngine based on IOCPEngine
         */
-       SocketEngine* Create(InspIRCd* Instance) { return new IOCPEngine(Instance); }
+       SocketEngine* Create() { return new IOCPEngine; }
 };
 
 #endif
-