n2nc::PacketManager Class Reference

#include <packetmanager.h>

Inheritance diagram for n2nc::PacketManager:

Inheritance graph
[legend]
Collaboration diagram for n2nc::PacketManager:

Collaboration graph
[legend]

List of all members.

Public Types

enum  srv_packet_type { SRV_PK_GARBAGE = 0, SRV_PK_GARBAGE_ACK, SRV_PK_DATA }
typedef struct srv_packet_header srv_packet_header_t

Public Member Functions

 PacketManager (net::Socket *sk)
virtual int send (void *buf, size_t len)
virtual int recv (void *buf, size_t len)
srv_packet_header_t * getRecvPkHeader ()
srv_packet_header_t * getSendPkHeader ()

Public Attributes

srv_packet_header m_pklastsent
srv_packet_header m_pklastrecvd
size_t mps
uint64_t totalsent
uint64_t totalrecvd

Classes

struct  srv_packet_header


Detailed Description

Author:
fabsoft <fabsoft@gmail.com>

Definition at line 13 of file packetmanager.h.


Member Function Documentation

int n2nc::PacketManager::send ( void *  buf,
size_t  len 
) [virtual]

Send data buf to remote peer

Reimplemented from n2nc::net::Socket.

Definition at line 27 of file packetmanager.cpp.

References n2nc::net::Socket::send().

Here is the call graph for this function:

int n2nc::PacketManager::recv ( void *  buf,
size_t  len 
) [virtual]

Receive len leght data from remote peer and store it to buf

Reimplemented from n2nc::net::Socket.

Definition at line 49 of file packetmanager.cpp.

References n2nc::net::Socket::recv().

Here is the call graph for this function:


Member Data Documentation

maximum packet size

Definition at line 38 of file packetmanager.h.


The documentation for this class was generated from the following files:

Generated on Mon Oct 6 19:32:32 2008 for n2nc by  doxygen 1.5.5