Item that encloses the application packet and some flags for it. More...
#include "tcp-tx-item.h"
Classes | |
struct | RateInformation |
Various rate-related information, can be accessed by TcpRateOps. More... | |
Public Member Functions | |
const Time & | GetLastSent () const |
Get a reference to the time the packet was sent for the last time. More... | |
Ptr< const Packet > | GetPacket () const |
Get the Packet underlying this item. More... | |
Ptr< Packet > | GetPacketCopy () const |
Get a copy of the Packet underlying this item. More... | |
RateInformation & | GetRateInformation () |
Get (to modify) the Rate Information of this item. More... | |
uint32_t | GetSeqSize () const |
Get the size in the sequence number space. More... | |
bool | IsRetrans () const |
Is the item retransmitted? More... | |
bool | IsSacked () const |
Is the item sacked? More... | |
void | Print (std::ostream &os, Time::Unit unit=Time::S) const |
Print the time. More... | |
Public Attributes | |
bool | m_retrans {false} |
Indicates if the segment is retransmitted. More... | |
Private Attributes | |
Time | m_lastSent |
Timestamp of the time at which the segment has been sent last time. More... | |
bool | m_lost {false} |
Indicates if the segment has been lost (RTO) More... | |
Ptr< Packet > | m_packet {nullptr} |
Application packet (can be null) More... | |
RateInformation | m_rateInfo |
Rate information of the item. More... | |
bool | m_sacked {false} |
Indicates if the segment has been SACKed. More... | |
SequenceNumber32 | m_startSeq {0} |
Sequence number of the item (if transmitted) More... | |
Friends | |
class | TcpTxBuffer |
Item that encloses the application packet and some flags for it.
Definition at line 32 of file tcp-tx-item.h.
const Time & ns3::TcpTxItem::GetLastSent | ( | ) | const |
Get a reference to the time the packet was sent for the last time.
Definition at line 91 of file tcp-tx-item.cc.
References m_lastSent.
Referenced by ns3::TcpRateLinux::SkbDelivered().
Get the Packet underlying this item.
Definition at line 85 of file tcp-tx-item.cc.
References m_packet.
Get a copy of the Packet underlying this item.
Definition at line 79 of file tcp-tx-item.cc.
References ns3::Packet::Copy(), and m_packet.
Referenced by ns3::TcpTxBuffer::DiscardUpTo(), and ns3::TcpSocketBase::SendDataPacket().
TcpTxItem::RateInformation & ns3::TcpTxItem::GetRateInformation | ( | ) |
Get (to modify) the Rate Information of this item.
Definition at line 97 of file tcp-tx-item.cc.
References m_rateInfo.
Referenced by TcpRateLinuxBasicTest::SendSkb(), TcpRateLinuxBasicTest::SkbDelivered(), ns3::TcpRateLinux::SkbDelivered(), and ns3::TcpRateLinux::SkbSent().
uint32_t ns3::TcpTxItem::GetSeqSize | ( | ) | const |
Get the size in the sequence number space.
Definition at line 61 of file tcp-tx-item.cc.
References ns3::Packet::GetSize(), and m_packet.
Referenced by Print(), TcpRateLinuxBasicTest::SendSkb(), TcpRateLinuxBasicTest::SkbDelivered(), and ns3::TcpRateLinux::SkbDelivered().
bool ns3::TcpTxItem::IsRetrans | ( | ) | const |
Is the item retransmitted?
Definition at line 73 of file tcp-tx-item.cc.
References m_retrans.
Referenced by ns3::TcpSocketBase::SendDataPacket().
bool ns3::TcpTxItem::IsSacked | ( | ) | const |
Is the item sacked?
Definition at line 67 of file tcp-tx-item.cc.
References m_sacked.
void ns3::TcpTxItem::Print | ( | std::ostream & | os, |
Time::Unit | unit = Time::S |
||
) | const |
Print the time.
os | ostream |
unit | Time::Unit |
Definition at line 24 of file tcp-tx-item.cc.
References ns3::Time::As(), GetSeqSize(), m_lastSent, m_lost, m_retrans, m_sacked, and m_startSeq.
Referenced by ns3::operator<<().
|
friend |
Definition at line 109 of file tcp-tx-item.h.
|
private |
Timestamp of the time at which the segment has been sent last time.
Definition at line 114 of file tcp-tx-item.h.
Referenced by ns3::TcpTxBuffer::CopyFromSequence(), GetLastSent(), ns3::TcpTxBuffer::MergeItems(), Print(), and ns3::TcpTxBuffer::SplitItems().
|
private |
Indicates if the segment has been lost (RTO)
Definition at line 113 of file tcp-tx-item.h.
Referenced by ns3::TcpTxBuffer::DiscardUpTo(), ns3::TcpTxBuffer::IsLostRFC(), ns3::TcpTxBuffer::MergeItems(), ns3::TcpTxBuffer::NextSeg(), Print(), ns3::TcpTxBuffer::RemoveFromCounts(), ns3::TcpTxBuffer::ResetSentList(), ns3::TcpTxBuffer::SplitItems(), and ns3::TcpTxBuffer::UpdateLostCount().
Application packet (can be null)
Definition at line 112 of file tcp-tx-item.h.
Referenced by ns3::TcpTxBuffer::~TcpTxBuffer(), ns3::TcpTxBuffer::BytesInFlightRFC(), ns3::TcpTxBuffer::DiscardUpTo(), ns3::TcpTxBuffer::FindHighestSacked(), ns3::TcpTxBuffer::GetNewSegment(), GetPacket(), GetPacketCopy(), ns3::TcpTxBuffer::GetPacketFromList(), GetSeqSize(), ns3::TcpTxBuffer::GetTransmittedSegment(), ns3::TcpTxBuffer::IsLostRFC(), ns3::TcpTxBuffer::IsRetransmittedDataAcked(), ns3::TcpTxBuffer::MergeItems(), ns3::TcpTxBuffer::NextSeg(), ns3::TcpTxBuffer::ResetLastSegmentSent(), ns3::TcpTxBuffer::SplitItems(), and ns3::TcpTxBuffer::UpdateLostCount().
|
private |
Rate information of the item.
Definition at line 118 of file tcp-tx-item.h.
Referenced by GetRateInformation().
bool ns3::TcpTxItem::m_retrans {false} |
Indicates if the segment is retransmitted.
Definition at line 104 of file tcp-tx-item.h.
Referenced by ns3::TcpTxBuffer::BytesInFlightRFC(), ns3::TcpTxBuffer::CopyFromSequence(), ns3::TcpTxBuffer::GetTransmittedSegment(), ns3::TcpTxBuffer::IsLostRFC(), IsRetrans(), ns3::TcpTxBuffer::IsRetransmittedDataAcked(), ns3::TcpTxBuffer::MergeItems(), ns3::TcpTxBuffer::NextSeg(), Print(), ns3::TcpTxBuffer::RemoveFromCounts(), ns3::TcpTxBuffer::ResetLastSegmentSent(), ns3::TcpTxBuffer::ResetSentList(), and ns3::TcpTxBuffer::SplitItems().
|
private |
Indicates if the segment has been SACKed.
Definition at line 116 of file tcp-tx-item.h.
Referenced by ns3::TcpTxBuffer::BytesInFlightRFC(), ns3::TcpTxBuffer::CopyFromSequence(), ns3::TcpTxBuffer::DiscardUpTo(), ns3::TcpTxBuffer::FindHighestSacked(), ns3::TcpTxBuffer::IsLostRFC(), ns3::TcpTxBuffer::IsRetransmittedDataAcked(), IsSacked(), ns3::TcpTxBuffer::MergeItems(), ns3::TcpTxBuffer::NextSeg(), Print(), ns3::TcpTxBuffer::RemoveFromCounts(), ns3::TcpTxBuffer::ResetSentList(), ns3::TcpTxBuffer::SplitItems(), and ns3::TcpTxBuffer::UpdateLostCount().
|
private |
Sequence number of the item (if transmitted)
Definition at line 111 of file tcp-tx-item.h.
Referenced by ns3::TcpTxBuffer::CopyFromSequence(), ns3::TcpTxBuffer::DiscardUpTo(), ns3::TcpTxBuffer::GetNewSegment(), ns3::TcpTxBuffer::GetPacketFromList(), ns3::TcpTxBuffer::IsRetransmittedDataAcked(), Print(), and ns3::TcpTxBuffer::SplitItems().