![]() |
VR-Link API Documentation for HLA 4
|
ClientSocket uses the vrlink packet server to read and write packets The destination address (incl. More...
Inheritance diagram for DtClientSocket:
Collaboration diagram for DtClientSocket:Public Member Functions | |
| DtClientSocket (int port, int recvQSize=DtCsQDefaultSize, unsigned short csFlags=DtCsFlagsDefault) | |
| DtClientSocket (int port, DtIpv4Addr destAddr, int recvQSize=DtCsQDefaultSize, unsigned short csFlags=DtCsFlagsDefault) | |
| ~DtClientSocket () | |
| int | sendTo (caddr_t packet, size_t size, DtIpv4Addr addr) |
| sendTo is a pure virtual function which subclasses should impliment to take packets and place them on a network interface. More... | |
| int | DtRecv (caddr_t, size_t) |
| int | DtRecv (caddr_t *buffptr, int *status=NULL) |
| This is slower as it does a memcpy(). More... | |
| int | listenToMulticastGroup (DtIpv4Addr multicastAddr) |
| int | dropMulticastGroup (DtIpv4Addr multicastAddr) |
| int | setMcastTtl (int ttl) |
| void | setUnbundling (int onOff) |
| DtIpv4Addr | lastSourceInetAddr () |
| int isUnbundling(); Is not currently implemented. More... | |
| void | DtBecomeNonBlocking (void) |
| int | readFd () |
| Get the file descriptor for reading and writing to this socket. More... | |
| int | writeFd () |
| virtual bool | isOk () const |
| bool | isInternal () |
| void | setPsMsgTimeout (int seconds) |
| void | notifyMe () |
| void | disconnectFromServer () |
| void | setPacketServerInternal () |
| void | setPacketServerExternal () |
| void | pingClients () |
| void | testClients () |
| void | terminatePacketServer () |
| void | requestServerState () |
| void | requestServerCStates () |
| void | setPacketServerUnbundling (int onOff) |
Public Member Functions inherited from DtSocket | |
| DtSocket () | |
| Default constructor. More... | |
| virtual | ~DtSocket () |
| Default Destructor. More... | |
| virtual int | DtSend (caddr_t packet, size_t size, DtIpv4Addr addr=DtUSE_DEFAULT_IP_ADDR) |
| DtSend is called when someone wants to send a packet to this "Socket", in other words, all outgoing messages are passed to this socket via DtSend(). More... | |
| caddr_t | DtRecv () |
| virtual DtFlushStatus | flush () |
| Send buffered messages. More... | |
| virtual DtFlushStatus | flush (long &byteCount) |
| Send buffered messages. More... | |
| virtual void | setReceiveBufferSize (int newsize) |
| Change the socket's receive buffer size that the OS uses to collect incoming data from the network. More... | |
| virtual void | setSendBufferSize (int newsize) |
| Change the socket's send buffer size that the OS uses when writing data to the network. More... | |
| virtual void | setBundling (int maxSize) |
| virtual int | isBundling () |
| virtual int | DtReportPktsRcvd (void) |
| virtual int | listenToMulticastGroup (DtIpv4Addr addr, DtIpv4Addr netInterface=DtUSE_DEFAULT_IP_ADDR) |
| virtual int | dropMulticastGroup (DtIpv4Addr addr, DtIpv4Addr netInterface=DtUSE_DEFAULT_IP_ADDR) |
| virtual void | setMcastDevice (DtIpv4Addr) |
| virtual DtFilterTest * | exerciseId () |
| virtual DtFilterTest * | protocolVersion () |
| virtual DtFilterTest * | pduKind () |
| virtual DtFilterTest * | ipAddr () |
Public Attributes | |
| DtTime | psMsgTimeout |
Public Attributes inherited from DtSocket | |
| int | myBlockingFlag |
| int | pkts_rcvd |
Protected Member Functions | |
| void | init (int port, DtIpv4Addr destAddr, int recvQSize, unsigned short csFlags) |
| int | timedRecv (caddr_t buf, size_t size, char *psKind) |
| void | drainNotifySocket () |
| void | checkGoAway () |
Protected Member Functions inherited from DtSocket | |
| virtual bool | accept (char *buf, DtIpv4Addr iaddr) |
Protected Attributes | |
| DtNetSocket * | netSock |
| bool | notifyPending |
| bool | myOkFlag |
| int | recvFd |
| int | sendFd |
| long | clientId |
Protected Attributes inherited from DtSocket | |
| BufferMap | myBufferMap |
| int | myBundlingFlag |
| int | myMaxBundleSize |
| int | mySockFd |
Private Member Functions | |
| void | processControlMsg (DtCsMsg *msg) |
| DtCsMsg * | getPsMsg (DtCsMsg *buf, char desiredKind) |
| void | cleanup (void) |
Private Attributes | |
| DtIpv4Addr | destAddr |
| char | clientSocketPath [DtCsClientPathSize] |
| int | serverPort |
| bool | internal |
| DtIpv4Addr | sourceAddr |
| DtNetFloat64 * | pktBuff8 |
| char * | shmAddr |
Additional Inherited Members | |
Static Public Member Functions inherited from DtSocket | |
| static void | initializeNetwork () |
| static void | setQuietSockets (bool quietVal) |
| These functions determine whether a socket will print messages, informative or error. More... | |
| static bool | areQuietSockets () |
Protected Types inherited from DtSocket | |
| typedef std::vector< char > | Buffer |
| typedef std::map< DtIpv4Addr, Buffer > | BufferMap |
Static Protected Member Functions inherited from DtSocket | |
| static int | getConfig (const char *device, int sock, ifconf *ifc) |
| Get ifconfig information by filling in ifc. More... | |
Static Protected Attributes inherited from DtSocket | |
| static bool | theAreQuietSockets |
| Should a socket print messages, informative or error. More... | |
ClientSocket uses the vrlink packet server to read and write packets The destination address (incl.
broadcast vs. internal-mode) are controlled by the packet server.
Constructor differences with respect to NetSocket: The destAddr is determined by the packet server (aka vrlink-daemon). All ClientSockets are currently ReadWrite.
| DtClientSocket::DtClientSocket | ( | int | port, |
| int | recvQSize = DtCsQDefaultSize, |
||
| unsigned short | csFlags = DtCsFlagsDefault |
||
| ) |
| DtClientSocket::DtClientSocket | ( | int | port, |
| DtIpv4Addr | destAddr, | ||
| int | recvQSize = DtCsQDefaultSize, |
||
| unsigned short | csFlags = DtCsFlagsDefault |
||
| ) |
| DtClientSocket::~DtClientSocket | ( | ) |
|
protected |
|
private |
| void DtClientSocket::disconnectFromServer | ( | ) |
|
protected |
| int DtClientSocket::dropMulticastGroup | ( | DtIpv4Addr | multicastAddr | ) |
|
virtual |
Reimplemented from DtSocket.
|
virtual |
This is slower as it does a memcpy().
Implements DtSocket.
|
protected |
| bool DtClientSocket::isInternal | ( | ) |
|
inlinevirtual |
int isUnbundling(); Is not currently implemented.
The answer depends on the state of the Packet Server.
Reimplemented from DtSocket.
| int DtClientSocket::listenToMulticastGroup | ( | DtIpv4Addr | multicastAddr | ) |
|
virtual |
Reimplemented from DtSocket.
| void DtClientSocket::pingClients | ( | ) |
|
private |
|
inlinevirtual |
| void DtClientSocket::requestServerCStates | ( | ) |
| void DtClientSocket::requestServerState | ( | ) |
|
virtual |
sendTo is a pure virtual function which subclasses should impliment to take packets and place them on a network interface.
This function is called by DtSend which deals with bundling.
Implements DtSocket.
| void DtClientSocket::setPacketServerExternal | ( | ) |
| void DtClientSocket::setPacketServerInternal | ( | ) |
| void DtClientSocket::setPacketServerUnbundling | ( | int | onOff | ) |
| void DtClientSocket::setPsMsgTimeout | ( | int | seconds | ) |
| void DtClientSocket::terminatePacketServer | ( | ) |
| void DtClientSocket::testClients | ( | ) |
|
protected |
|
protected |
|
private |
|
private |
|
private |
|
protected |
|
protected |
|
protected |
|
private |
| DtTime DtClientSocket::psMsgTimeout |
|
protected |
|
protected |
|
private |
|
private |
|
private |