#include <itpp/protocol/tcp.h>
Inheritance diagram for itpp::TCP_Packet:
Public Member Functions | |
TCP_Packet () | |
TCP_Packet (const TCP_Packet &packet) | |
virtual | ~TCP_Packet () |
virtual TCP_Packet & | clone () const |
void | set_segment (const TCP_Segment &seg) |
TCP_Segment | get_segment () const |
void | set_wnd (unsigned val) |
unsigned | get_wnd () const |
void | set_ACK (Sequence_Number val) |
Sequence_Number | get_ACK () const |
void | set_session_id (int val) |
int | get_session_id () const |
void | set_destination_port (unsigned val) |
unsigned | get_destination_port () const |
void | set_source_port (unsigned val) |
unsigned | get_source_port () const |
void | set_info (unsigned ssThresh, unsigned recWnd, unsigned cWnd, double estRTT, Sequence_Number sndUna, Sequence_Number sndNxt, bool isRtx) |
virtual void | print_header (std::ostream &out) const |
void | set_bit_size (int packet_size) |
set size of packet in bits | |
int | bit_size () |
get size of packet in bits | |
Protected Attributes | |
unsigned | fDestinationPort |
unsigned | fSourcePort |
TCP_Segment | fSegment |
data segment to be transmitted | |
Sequence_Number | fACK |
acknowledgment (next expected sn) | |
unsigned | fWnd |
window size (advertised by receiver) | |
int | fSessionId |
session identifier | |
TDebugInfo * | fInfo |
Friends | |
std::ostream & | operator<< (std::ostream &, TCP_Packet &) |
Classes | |
struct | TDebugInfo |
The class contains a segment of type TCP_Segment with sequence numbers for begin and end of the segment. This is only used in data packets (i.e. from sender to receiver) while there are also fields containing sequence number for the next expected segment (used to ACK data packets, i.e. from receiver to sender) and for the advertised receiver window.
TCP_Packet has an additional field for the session id which my be compared with the pair (source port, destination port) in a real world TCP/IP packet.
Furthermore, some debug info containing state information for TCP sender or receiver may be attached to the message.
Definition at line 167 of file tcp.h.
void itpp::Packet::set_bit_size | ( | int | packet_size | ) | [inline, inherited] |
set size of packet in bits
Definition at line 52 of file packet.h.
References it_assert.
Referenced by itpp::Packet::Packet().
int itpp::Packet::bit_size | ( | ) | [inline, inherited] |
get size of packet in bits
Definition at line 55 of file packet.h.
Referenced by itpp::Front_Drop_Queue::pop(), itpp::Front_Drop_Queue::push(), and itpp::TCP_Server_Application::write_to_net().
TCP_Segment itpp::TCP_Packet::fSegment [protected] |
data segment to be transmitted
Definition at line 198 of file tcp.h.
Referenced by get_segment(), and set_segment().
Sequence_Number itpp::TCP_Packet::fACK [protected] |
unsigned itpp::TCP_Packet::fWnd [protected] |
int itpp::TCP_Packet::fSessionId [protected] |
session identifier
Definition at line 201 of file tcp.h.
Referenced by get_session_id(), and set_session_id().
Generated on Wed Apr 18 11:20:05 2007 for IT++ by Doxygen 1.5.2