Dashel::UDPSocketStream Class Reference

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

Inheritance diagram for Dashel::UDPSocketStream:
Inheritance graph
[legend]

List of all members.

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.

Detailed Description

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

Definition at line 534 of file dashel-posix.cpp.


Constructor & Destructor Documentation

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.


Member Function Documentation

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.

Parameters:
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.

Parameters:
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.

Parameters:
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.

Parameters:
dest IP address to send packet to

Implements Dashel::PacketStream.

Definition at line 579 of file dashel-posix.cpp.


Member Data Documentation

HANDLE Dashel::UDPSocketStream::hev [private]

Event for real data.

Definition at line 1139 of file dashel-win32.cpp.

Definition at line 537 of file dashel-posix.cpp.

Socket handle.

Definition at line 1136 of file dashel-win32.cpp.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines


asebaros
Author(s): $author
autogenerated on Mon Sep 5 08:42:17 2011