LRT14  1.0
 All Classes Namespaces Functions Variables Enumerations Enumerator
NetConnection.h
1 #ifndef RHESUS_NET_CONNECTION_H_
2 #define RHESUS_NET_CONNECTION_H_
3 
4 #include <stdio.h>
5 
6 #include <unistd.h>
7 #include <sys/types.h>
8 #include <sys/socket.h>
9 
10 #include "NetPeer.h"
11 
12 namespace Rhesus
13 {
14 namespace Messenger
15 {
16  class NetConnection
17  {
18  private:
19  int m_socket;
20 
21  sockaddr_in m_remoteEndpoint;
22  NetPeer* m_netPeer;
23 
24  public:
25  sockaddr_in* RemoteEndpoint();
26 
27  NetConnection(sockaddr_in iep, NetPeer* peer);
28 
29  void Send(NetBuffer* buff, NetChannel::Enum method, int channel);
30  };
31 }
32 }
33 
34 #endif