UDP Socket, uses sendto/recvfrom for read/write. More...

Public Member Functions | |
| virtual bool | isDataInRecvBuffer () const |
| Return true while there is some unread data in the reception buffer. | |
| virtual void | receive (IPV4Address &source) |
| Receive a packet and make its payload available for reading. | |
| virtual void | receive (IPV4Address &source) |
| Receive a packet and make its payload available for reading. | |
| virtual bool | receiveDataAndCheckDisconnection () |
| If necessary, read a byte and check for disconnection; return true on disconnection, fales otherwise. | |
| virtual void | send (const IPV4Address &dest) |
| Send all written data to an IP address in a single packet. | |
| virtual void | send (const IPV4Address &dest) |
| Send all written data to an IP address in a single packet. | |
| UDPSocketStream (const std::string &targetName) | |
| Create as UDP socket stream on a specific port. | |
| UDPSocketStream (const string &targetName) | |
| Create as UDP socket stream on a specific port. | |
| virtual | ~UDPSocketStream () |
Private Attributes | |
| HANDLE | hev |
| Event for real data. | |
| bool | selectWasCalled |
| SOCKET | sock |
| Socket handle. | |
UDP Socket, uses sendto/recvfrom for read/write.
Definition at line 534 of file dashel-posix.cpp.
| Dashel::UDPSocketStream::UDPSocketStream | ( | const string & | targetName | ) | [inline] |
Create as UDP socket stream on a specific port.
Definition at line 541 of file dashel-posix.cpp.
| Dashel::UDPSocketStream::UDPSocketStream | ( | const std::string & | targetName | ) | [inline] |
Create as UDP socket stream on a specific port.
Definition at line 1143 of file dashel-win32.cpp.
| virtual Dashel::UDPSocketStream::~UDPSocketStream | ( | ) | [inline, virtual] |
Definition at line 1189 of file dashel-win32.cpp.
| virtual bool Dashel::UDPSocketStream::isDataInRecvBuffer | ( | ) | const [inline, virtual] |
Return true while there is some unread data in the reception buffer.
Implements Dashel::SelectableStream.
Definition at line 608 of file dashel-posix.cpp.
| virtual void Dashel::UDPSocketStream::receive | ( | IPV4Address & | source | ) | [inline, virtual] |
Receive a packet and make its payload available for reading.
Block until a packet is available.
| source | IP address from where the packet originates. |
Implements Dashel::PacketStream.
Definition at line 1207 of file dashel-win32.cpp.
| virtual void Dashel::UDPSocketStream::receive | ( | IPV4Address & | source | ) | [inline, virtual] |
Receive a packet and make its payload available for reading.
Block until a packet is available.
| source | IP address from where the packet originates. |
Implements Dashel::PacketStream.
Definition at line 592 of file dashel-posix.cpp.
| virtual bool Dashel::UDPSocketStream::receiveDataAndCheckDisconnection | ( | ) | [inline, virtual] |
If necessary, read a byte and check for disconnection; return true on disconnection, fales otherwise.
Implements Dashel::SelectableStream.
Definition at line 607 of file dashel-posix.cpp.
| virtual void Dashel::UDPSocketStream::send | ( | const IPV4Address & | dest | ) | [inline, virtual] |
Send all written data to an IP address in a single packet.
| dest | IP address to send packet to |
Implements Dashel::PacketStream.
Definition at line 1194 of file dashel-win32.cpp.
| virtual void Dashel::UDPSocketStream::send | ( | const IPV4Address & | dest | ) | [inline, virtual] |
Send all written data to an IP address in a single packet.
| dest | IP address to send packet to |
Implements Dashel::PacketStream.
Definition at line 579 of file dashel-posix.cpp.
HANDLE Dashel::UDPSocketStream::hev [private] |
Event for real data.
Definition at line 1139 of file dashel-win32.cpp.
bool Dashel::UDPSocketStream::selectWasCalled [mutable, private] |
Definition at line 537 of file dashel-posix.cpp.
SOCKET Dashel::UDPSocketStream::sock [private] |
Socket handle.
Definition at line 1136 of file dashel-win32.cpp.