2012-04-02 08:56:30 +02:00
|
|
|
#ifndef TCPSOCKET_H
|
|
|
|
#define TCPSOCKET_H
|
2012-03-28 13:24:49 +02:00
|
|
|
|
|
|
|
namespace icinga
|
|
|
|
{
|
|
|
|
|
2012-04-06 08:56:52 +02:00
|
|
|
class I2_BASE_API TCPSocket : public Socket
|
2012-03-28 13:24:49 +02:00
|
|
|
{
|
2012-04-26 16:45:00 +02:00
|
|
|
private:
|
2012-04-27 09:54:07 +02:00
|
|
|
void MakeSocket(int family);
|
2012-04-26 16:45:00 +02:00
|
|
|
|
2012-03-28 13:24:49 +02:00
|
|
|
public:
|
2012-04-02 20:50:35 +02:00
|
|
|
typedef shared_ptr<TCPSocket> Ptr;
|
|
|
|
typedef weak_ptr<TCPSocket> WeakPtr;
|
2012-03-28 13:24:49 +02:00
|
|
|
|
2012-04-27 09:54:07 +02:00
|
|
|
void Bind(unsigned short port, int family);
|
|
|
|
void Bind(const char *hostname, unsigned short port, int family);
|
2012-03-28 13:24:49 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
}
|
|
|
|
|
2012-04-02 08:56:30 +02:00
|
|
|
#endif /* TCPSOCKET_H */
|