crossroads

Git mirror of https://crossroads.e-tunity.com/
git clone git://git.finwo.net/app/crossroads
Log | Files | Refs | LICENSE

tcpdispatcher (639B)


      1 #ifndef _TCPDISPATCHER_
      2 #define _TCPDISPATCHER_
      3 
      4 #include "Dispatchers/dispatcher/dispatcher"
      5 #include "netbuffer/netbuffer"
      6 #include "httpbuffer/httpbuffer"
      7 #include "ipstore/ipstore"
      8 #include "SocketHandling/socket/socket"
      9 
     10 class TcpDispatcher: public Dispatcher {
     11 public:
     12     TcpDispatcher(Socket &clientsock): Dispatcher(clientsock), netbuffer() {}    	
     13 
     14     virtual void execute();
     15     virtual void dispatch();
     16     virtual void handle();
     17 
     18     unsigned readchunk(int src);
     19 
     20     Httpbuffer &buf() 				{ return netbuffer; }
     21 
     22 private:
     23     Httpbuffer netbuffer;			// same as netbuffer, but
     24     						// httpdispatcher reuses it
     25 };
     26 
     27 #endif