simple-socket library 1.1.5

TCPSocket.h

Go to the documentation of this file.
00001 #ifndef NET_TCPSocket_h__
00002 #define NET_TCPSocket_h__
00003 
00004 #include "SocketHandle.h"
00005 #include "InternetSocket.h"
00006 
00007 namespace NET
00008 {
00010     class TCPSocket : public InternetSocket
00011     {
00012     public:
00014         typedef SocketHandle<TCPSocket> Handle;
00015 
00020         TCPSocket();
00021 
00026         TCPSocket( Handle handle);
00027 
00029 
00046         int sendAll( const void* buffer, size_t len);
00047 
00049 
00065         void listen( int backlog = 5);
00066 
00068 
00083         Handle accept() const;
00084 
00086 
00106         Handle timedAccept( int timeout) const;
00107     };
00108 
00109 } // namespace NET
00110 
00111 #endif // NET_TCPSocket_h__