30 #ifndef PTLIB_UDPSOCKET_H
31 #define PTLIB_UDPSOCKET_H
54 int iAddressFamily = AF_INET
58 int iAddressFamily = AF_INET
104 int mtuDiscovery = -1
108 int mtuDiscovery = -1
164 #include "msos/ptlib/udpsock.h"
166 #include "unix/ptlib/udpsock.h"
170 AddressAndPort m_sendAddressAndPort;
171 AddressAndPort m_lastReceiveAddressAndPort;
175 #endif // PTLIB_UDPSOCKET_H
bool SetSendAddress(const Address &address, WORD port, int mtuDiscovery=-1)
Set the address to use for connectionless Write() or Windows QoS.
virtual void InternalGetSendAddress(PIPSocketAddressAndPort &addr) const
A socket channel that uses the UDP transport on the Internet Protocol.
Definition: udpsock.h:42
virtual PBoolean OpenSocket()
PBoolean Connect(const PString &address)
Override of PSocket functions to allow connectionless writes.
A class describing an IP address and port number combination.
Definition: ipsock.h:278
PUDPSocket(WORD port=0, int iAddressFamily=AF_INET)
Create a UDP socket.
virtual bool InternalListen(const Address &bind, unsigned queueSize, WORD port, Reusability reuse)
virtual bool InternalReadFrom(Slice *slices, size_t sliceCount, PIPSocketAddressAndPort &ipAndPort)
PBoolean Read(void *buf, PINDEX len)
Override of PChannel functions to allow connectionless reads.
PBoolean Write(const void *buf, PINDEX len)
Override of PChannel functions to allow connectionless writes.
virtual void InternalSetLastReceiveAddress(const PIPSocketAddressAndPort &addr)
virtual void InternalGetLastReceiveAddress(PIPSocketAddressAndPort &addr) const
Structure that defines a "slice" of memory to be written to.
Definition: socket.h:434
int GetCurrentMTU()
Get the current MTU size.
bool PBoolean
Definition: object.h:174
virtual bool InternalSetSendAddress(const PIPSocketAddressAndPort &addr, int mtuDiscovery=-1)
PString GetSendAddress() const
The character string class.
Definition: pstring.h:108
A class describing an IP address.
Definition: ipsock.h:59
PString GetLastReceiveAddress() const
Internet Protocol Datagram Socket class.
Definition: ipdsock.h:41
virtual const char * GetProtocolName() const
This function returns the protocol name for the socket type.
Reusability
Flags to reuse of port numbers in Listen() function.
Definition: socket.h:85