|
| | DtGroupSocket (int port=DtDEFAULT_PORT, DtU8 flags=DtReadWrite, DtIpv4Addr devAddr=0) |
| | Constructor - uses default address for listening. More...
|
| |
| | DtGroupSocket (int port, DtIpv4Addr addr, DtU8 flags, DtIpv4Addr devAddr=0) |
| | Constructor - uses addr for listening. More...
|
| |
| virtual | ~DtGroupSocket () |
| | Destructor. More...
|
| |
| virtual void | removeAllRemoteSites () |
| | Clear the list of remote sites. More...
|
| |
| virtual int | DtSend (caddr_t pkt, size_t size, DtIpv4Addr addr) |
| | Virtual function override - send to all remote sites. More...
|
| |
| virtual void | addRemoteSite (DtIpv4Addr addr) |
| | Add/remove a remote site to send to. More...
|
| |
| virtual void | removeRemoteSite (DtIpv4Addr addr) |
| |
| virtual int | sendToAllRemoteSites (caddr_t pkt, size_t size, DtIpv4Addr dwSkipAddr=0) |
| | Send to all remote sites except dwSkipAddr. More...
|
| |
| virtual const DtList * | remoteSitesList () const |
| | Return the remote sites list. More...
|
| |
| | DtNetSocket (int port=DtDEFAULT_PORT, DtU8 flags=DtReadWrite, DtIpv4Addr devAddr=0) |
| | Constructor. More...
|
| |
| | DtNetSocket (int port, DtIpv4Addr destAddr, DtU8 flags, DtIpv4Addr devAddr=0) |
| | Constructor. More...
|
| |
| | DtNetSocket (char *dummy, int sockfd, DtU8 flags=DtReadWrite) |
| | Allows you to create a DtNetSocket that uses a pre-existing socket. More...
|
| |
| virtual | ~DtNetSocket () |
| | Destructor. More...
|
| |
| virtual int | sendTo (caddr_t packet, size_t size, DtIpv4Addr addr) |
| | Virtual function override. More...
|
| |
| virtual int | DtRecv (caddr_t *buffptr, int *status=NULL) |
| | DtNetSocket implements DtRecv by calling a system call to recvfrom on its UDP socket. More...
|
| |
| virtual int | DtRecv (caddr_t buff, size_t) |
| | DtNetSocket implements DtRecv by calling a system call to recvfrom on its UDP socket. More...
|
| |
| virtual DtIpv4Addr | lastSourceInetAddr () |
| | Return the IP address of the sender of the last packet we've received. More...
|
| |
| virtual void | DtBecomeNonBlocking (void) |
| | Make the socket non-blocking. More...
|
| |
| virtual int | readFd () |
| | Return read/write file descriptor of the UDP socket being used for sending and receiving. More...
|
| |
| virtual int | writeFd () |
| |
| virtual bool | isOk () const |
| | Returns 1 if the socket's constructor initialization was successful, 0 otherwise. More...
|
| |
| virtual int | setMcastTtl (int ttl) |
| | Set the TTL (time to live) value for multicast packets. More...
|
| |
| virtual void | setFilterPort (const int &port) |
| |
| virtual void | setSendPort (const int &port) |
| |
| virtual void | setBundling (int maxBundleSize, bool enableUnbundling, int minPacketSize, int sizeOffset, int sizeLength, bool testDisHeader) |
| | Set all bundling parameters Disables bundling if max. More...
|
| |
| virtual void | setBundling (int maxBundleSize) |
| | Call through to DtSocket::setBundling to prevent compiler warnings. More...
|
| |
| virtual void | setUnbundling (int onOff) |
| | Pass 0 to setUnbundling to turn unbundling off, 1 to turn it on. More...
|
| |
| virtual int | isUnbundling () |
| | Set all bundling parameters Disables bundling if max. More...
|
| |
| virtual int | minPacketSize () |
| |
| virtual void | setMinPacketSize (int size) |
| |
| virtual int | sizeOffset () |
| |
| virtual void | setSizeOffset (int offset) |
| |
| virtual int | sizeLength () |
| |
| virtual void | setSizeLength (int length) |
| |
| virtual bool | testDisHeader () |
| |
| virtual void | enableDisHeaderTest (bool shouldTest) |
| |
| virtual int | listenToMulticastGroup (DtIpv4Addr multicastAddr, DtIpv4Addr netInterface=DtUSE_DEFAULT_IP_ADDR) |
| |
| virtual int | dropMulticastGroup (DtIpv4Addr multicastAddr, DtIpv4Addr netInterface=DtUSE_DEFAULT_IP_ADDR) |
| |
| virtual void | setMcastDevice (DtIpv4Addr devAddr) |
| |
| virtual DtIpv4Addr | mcastDevice () const |
| |
| | DtSocket () |
| | Default constructor. More...
|
| |
| virtual | ~DtSocket () |
| | Default Destructor. 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 int | isBundling () |
| |
| virtual int | DtReportPktsRcvd (void) |
| |
| virtual void | notifyMe () |
| |
| virtual DtFilterTest * | exerciseId () |
| |
| virtual DtFilterTest * | protocolVersion () |
| |
| virtual DtFilterTest * | pduKind () |
| |
| virtual DtFilterTest * | ipAddr () |
| |
|
| DtListItem * | findItem (DtIpv4Addr addr) const |
| |
| | DtGroupSocket (const DtGroupSocket &) |
| | Copy CTOR Not implemented. More...
|
| |
| DtGroupSocket & | operator= (const DtGroupSocket &) |
| | Assignment operator not implemented. More...
|
| |
| void | init (int port, DtIpv4Addr dest_addr, DtU8 flags, DtIpv4Addr devAddr=0) |
| | Called from all constructors. More...
|
| |
| virtual int | dataLeftInCurrentBundle () |
| | Is there still data left in the last received packet? More...
|
| |
| virtual int | retrySendTo (caddr_t packet, size_t size, sockaddr_in &dest) |
| | If retry is enabled, retry failed packet send theMaxSendRetries times. More...
|
| |
| virtual int | recvWithStatus (caddr_t *buffptr, int *status) |
| | Sets buffptr to point to the next packet (might be next in bundle, might require a read from net) and returns size. More...
|
| |
| virtual int | recvFromNet (caddr_t *buffptr) |
| | Grabs the next packet from the network, and puts it into myPktBuff. More...
|
| |
| virtual int | recvWithUnbundling (caddr_t *buffptr) |
| | Used by recvWithStatus if unbundling is on. More...
|
| |
| int | initSocket () |
| | Initialize the socket. More...
|
| |
| int | initWrite (DtIpv4Addr dest) |
| | Initialize for writing. More...
|
| |
| int | initRead (DtIpv4Addr dest) |
| | Initialize for reading, including performing bind. More...
|
| |
| virtual int | privateListenToMulticastGroup (DtIpv4Addr multicastAddr, int on_init=0, DtIpv4Addr netInterface=DtUSE_DEFAULT_IP_ADDR) |
| | Helper function for listenToMulticastGroup. More...
|
| |
| virtual void | findNextPacket () |
| | Sets myNextPacket to point to the next packet. More...
|
| |
| virtual unsigned int | getNextPacketSize () |
| | Gets the size of the next packet pointed to by myNextPacket. More...
|
| |
| virtual unsigned int | currentHeaderMatchesFirstInBundle () |
| | DIS-specific function to help decide if unbundling is successful. More...
|
| |
| | DtNetSocket (const DtNetSocket &) |
| | Not Implemented. More...
|
| |
| DtNetSocket & | operator= (const DtNetSocket &) |
| | Not Implemented. More...
|
| |
| virtual bool | accept (char *buf, DtIpv4Addr iaddr) |
| |
|
| static int | isMulticastAddr (DtIpv4Addr addr) |
| | Returns 1 if addr is a multicast address, 0 otherwise. More...
|
| |
| static int | enableBroadcast (int sockfd) |
| | Make sockfd capable of broadcasting. More...
|
| |
| static void | makeNonBlocking (int sockfd) |
| | Make sockfd non-blocking. More...
|
| |
| static int | makeReusable (int sockfd) |
| | Make port/address reusable by other sockets. More...
|
| |
| static void | setRetryOnSend (unsigned int numRetries, double waitPeriod) |
| | Make socket retry numRetries times ( waiting for waitPeriod between ) when sendto fails ( numRetries = 0 means message will be dropped ) More...
|
| |
| static DtIpv4Addr | inetBroadcastOfDevice (const char *device=NULL) |
| | Obtain information about a device. More...
|
| |
| static DtIpv4Addr | inetAddrOfDevice (const char *device=NULL) |
| |
| static DtIpv4Addr | netMaskOfDevice (const char *device=NULL) |
| |
| static DtIpv4Addr | firstHostInetAddr () |
| |
| static void | setInetAddr (sockaddr_in &s, u_long addr, int port) |
| | Fill out a sockaddr_in structure. More...
|
| |
| static void | initializeNetwork () |
| |
| static void | setQuietSockets (bool quietVal) |
| | These functions determine whether a socket will print messages, informative or error. More...
|
| |
| static bool | areQuietSockets () |
| |
| int | myBlockingFlag |
| |
| int | pkts_rcvd |
| |
| static DtInitErrorAction | initErrorAction |
| |
| typedef std::vector< char > | Buffer |
| |
typedef std::map< DtIpv4Addr,
Buffer > | BufferMap |
| |
| static ifreq * | findIfr (const char *device, int sock, ifconf *ifc) |
| | Find a device. More...
|
| |
| static DtIpv4Addr | netMaskOfIfr (ifreq *ifr, int sock) |
| | Obtain information about a device. Dummy socket needed for ioctls. More...
|
| |
| static DtIpv4Addr | inetAddrOfIfr (ifreq *ifr, int sock) |
| |
| static DtIpv4Addr | inetBroadcastOfIfr (ifreq *ifr, int sock) |
| |
| static bool | capableOfIpBroadcast (ifreq *ifr, int sock) |
| |
| static int | getConfig (const char *device, int sock, ifconf *ifc) |
| | Get ifconfig information by filling in ifc. More...
|
| |
| static unsigned int | theMaxSendRetries |
| |
| static double | theSendRetryPeriod |
| |
| static bool | theAreQuietSockets |
| | Should a socket print messages, informative or error. More...
|
| |