#include <sot/talos_balance/sdk_qualisys/Network.h>
Public Member Functions | |
CNetwork () | |
~CNetwork () | |
bool | Connect (const char *pServerAddr, unsigned short nPort) |
bool | Connected () const |
bool | CreateUDPSocket (unsigned short &nUDPPort, bool bBroadcast=false) |
void | Disconnect () |
int | GetError () const |
char * | GetErrorString () |
unsigned short | GetUdpBroadcastServerPort () |
unsigned short | GetUdpServerPort () |
bool | IsLocalAddress (unsigned int nAddr) const |
int | Receive (char *rtDataBuff, int nDataBufSize, bool bHeader, int nTimeout, unsigned int *ipAddr=nullptr) |
bool | Send (const char *pSendBuf, int nSize) |
bool | SendUDPBroadcast (const char *pSendBuf, int nSize, short nPort, unsigned int nFilterAddr=0) |
CNetwork | ( | ) |
Definition at line 45 of file Network.cpp.
References INVALID_SOCKET.
~CNetwork | ( | ) |
Definition at line 57 of file Network.cpp.
bool Connect | ( | const char * | pServerAddr, |
unsigned short | nPort | ||
) |
Definition at line 87 of file Network.cpp.
References closesocket, and SOCKET_ERROR.
Referenced by CRTProtocol::Connect().
bool Connected | ( | ) | const |
Definition at line 171 of file Network.cpp.
References INVALID_SOCKET.
Referenced by CRTProtocol::Connected().
bool CreateUDPSocket | ( | unsigned short & | nUDPPort, |
bool | bBroadcast = false |
||
) |
Definition at line 176 of file Network.cpp.
References closesocket, GetUdpServerPort(), INVALID_SOCKET, ioctlsocket, SOCKADDR, and SOCKET.
Referenced by CRTProtocol::Connect(), and CRTProtocol::DiscoverRTServer().
void Disconnect | ( | ) |
Definition at line 157 of file Network.cpp.
References closesocket, INVALID_SOCKET, and SD_SEND.
Referenced by CRTProtocol::Disconnect().
int GetError | ( | ) | const |
Definition at line 514 of file Network.cpp.
Referenced by CRTProtocol::Connect().
char * GetErrorString | ( | ) |
Definition at line 508 of file Network.cpp.
Referenced by CRTProtocol::Connect(), CRTProtocol::DiscoverRTServer(), and CRTProtocol::GetErrorString().
unsigned short GetUdpBroadcastServerPort | ( | ) |
Definition at line 259 of file Network.cpp.
References GetUdpServerPort().
unsigned short GetUdpServerPort | ( | ) |
Definition at line 254 of file Network.cpp.
Referenced by CreateUDPSocket(), GetUdpBroadcastServerPort(), and CRTProtocol::GetUdpServerPort().
bool IsLocalAddress | ( | unsigned int | nAddr | ) | const |
Definition at line 520 of file Network.cpp.
Referenced by CRTProtocol::DiscoverRTServer().
int Receive | ( | char * | rtDataBuff, |
int | nDataBufSize, | ||
bool | bHeader, | ||
int | nTimeout, | ||
unsigned int * | ipAddr = nullptr |
||
) |
Definition at line 266 of file Network.cpp.
References INVALID_SOCKET, SOCKET_ERROR, and TIMEVAL.
Referenced by CRTProtocol::DiscoverRTServer(), and CRTProtocol::ReceiveRTPacket().
bool Send | ( | const char * | pSendBuf, |
int | nSize | ||
) |
Definition at line 374 of file Network.cpp.
References SOCKET_ERROR.
Referenced by CRTProtocol::GetErrorString().
bool SendUDPBroadcast | ( | const char * | pSendBuf, |
int | nSize, | ||
short | nPort, | ||
unsigned int | nFilterAddr = 0 |
||
) |
Definition at line 393 of file Network.cpp.
References INVALID_SOCKET.
Referenced by CRTProtocol::DiscoverRTServer().