#include "ns3/applications-module.h"
#include "ns3/core-module.h"
#include "ns3/internet-apps-module.h"
#include "ns3/internet-module.h"
#include "ns3/network-module.h"
#include "ns3/point-to-point-module.h"
#include "ns3/traffic-control-module.h"
#include <fstream>
#include <iostream>
#include <string>
Go to the source code of this file.
Functions | |
void | ScheduleFirstDctcpTraceConnection (std::ofstream *ofStream) |
Schedule trace connection. | |
void | ScheduleFirstPacketSinkConnection () |
Schedule trace connection. | |
void | ScheduleFirstTcpCwndTraceConnection (std::ofstream *ofStream) |
Schedule trace connection. | |
void | ScheduleFirstTcpRttTraceConnection (std::ofstream *ofStream) |
Schedule trace connection. | |
void | ScheduleSecondDctcpTraceConnection (std::ofstream *ofStream) |
Schedule trace connection. | |
void | ScheduleSecondPacketSinkConnection () |
Schedule trace connection. | |
void | ScheduleSecondTcpCwndTraceConnection (std::ofstream *ofStream) |
Schedule trace connection. | |
void | ScheduleSecondTcpRttTraceConnection (std::ofstream *ofStream) |
Schedule trace connection. | |
void | TraceFirstCwnd (std::ofstream *ofStream, uint32_t oldCwnd, uint32_t newCwnd) |
Trace first congestion window. | |
void | TraceFirstDctcp (std::ofstream *ofStream, uint32_t bytesMarked, uint32_t bytesAcked, double alpha) |
Trace first TcpDctcp. | |
void | TraceFirstRtt (std::ofstream *ofStream, Time oldRtt, Time newRtt) |
Trace first RTT. | |
void | TraceFirstRx (Ptr< const Packet > packet, const Address &address) |
Trace first Rx. | |
void | TraceFirstThroughput (std::ofstream *ofStream, Time throughputInterval) |
Trace the first throughput. | |
void | TraceMarksFrequency (std::ofstream *ofStream, Time marksSamplingInterval) |
Trace marks frequency. | |
void | TracePingRtt (std::ofstream *ofStream, uint16_t, Time rtt) |
Trace ping RTT. | |
void | TraceQueueDrop (std::ofstream *ofStream, Ptr< const QueueDiscItem > item) |
Trace queue drop. | |
void | TraceQueueLength (std::ofstream *ofStream, DataRate queueLinkRate, uint32_t oldVal, uint32_t newVal) |
Trace queue length. | |
void | TraceQueueMark (std::ofstream *ofStream, Ptr< const QueueDiscItem > item, const char *reason) |
Trace queue marks. | |
void | TraceSecondCwnd (std::ofstream *ofStream, uint32_t oldCwnd, uint32_t newCwnd) |
Trace second congestion window. | |
void | TraceSecondDctcp (std::ofstream *ofStream, uint32_t bytesMarked, uint32_t bytesAcked, double alpha) |
Trace second TcpDctcp. | |
void | TraceSecondRtt (std::ofstream *ofStream, Time oldRtt, Time newRtt) |
Trace second RTT. | |
void | TraceSecondRx (Ptr< const Packet > packet, const Address &address) |
Trace second Rx. | |
void | TraceSecondThroughput (std::ofstream *ofStream, Time throughputInterval) |
Trace the second throughput. | |
Variables | |
uint32_t | g_dropsObserved = 0 |
Number of dropped packets observed. | |
uint32_t | g_firstBytesReceived = 0 |
First received packet size. | |
uint32_t | g_marksObserved = 0 |
Number of marked packets observed. | |
uint32_t | g_secondBytesReceived = 0 |
Second received packet size. | |
std::string | g_validate = "" |
Empty string disables validation. | |
bool | g_validationFailed = false |
True if validation failed. | |
void ScheduleFirstDctcpTraceConnection | ( | std::ofstream * | ofStream | ) |
Schedule trace connection.
ofStream | Output filestream. |
Definition at line 524 of file tcp-validation.cc.
References ns3::Config::ConnectWithoutContextFailSafe(), ns3::MakeBoundCallback(), and TraceFirstDctcp().
void ScheduleFirstPacketSinkConnection | ( | ) |
Schedule trace connection.
Definition at line 548 of file tcp-validation.cc.
References ns3::Config::ConnectWithoutContextFailSafe(), ns3::MakeCallback(), and TraceFirstRx().
void ScheduleFirstTcpCwndTraceConnection | ( | std::ofstream * | ofStream | ) |
Schedule trace connection.
ofStream | Output filestream. |
Definition at line 499 of file tcp-validation.cc.
References ns3::Config::ConnectWithoutContextFailSafe(), ns3::MakeBoundCallback(), and TraceFirstCwnd().
void ScheduleFirstTcpRttTraceConnection | ( | std::ofstream * | ofStream | ) |
Schedule trace connection.
ofStream | Output filestream. |
Definition at line 512 of file tcp-validation.cc.
References ns3::Config::ConnectWithoutContextFailSafe(), ns3::MakeBoundCallback(), and TraceFirstRtt().
void ScheduleSecondDctcpTraceConnection | ( | std::ofstream * | ofStream | ) |
Schedule trace connection.
ofStream | Output filestream. |
Definition at line 537 of file tcp-validation.cc.
References ns3::Config::ConnectWithoutContextFailSafe(), ns3::MakeBoundCallback(), and TraceSecondDctcp().
void ScheduleSecondPacketSinkConnection | ( | ) |
Schedule trace connection.
Definition at line 582 of file tcp-validation.cc.
References ns3::Config::ConnectWithoutContext(), ns3::MakeCallback(), and TraceSecondRx().
void ScheduleSecondTcpCwndTraceConnection | ( | std::ofstream * | ofStream | ) |
Schedule trace connection.
ofStream | Output filestream. |
Definition at line 560 of file tcp-validation.cc.
References ns3::Config::ConnectWithoutContext(), ns3::MakeBoundCallback(), and TraceSecondCwnd().
void ScheduleSecondTcpRttTraceConnection | ( | std::ofstream * | ofStream | ) |
Schedule trace connection.
ofStream | Output filestream. |
Definition at line 572 of file tcp-validation.cc.
References ns3::Config::ConnectWithoutContext(), ns3::MakeBoundCallback(), and TraceSecondRtt().
Trace first congestion window.
ofStream | Output filestream. |
oldCwnd | Old value. |
newCwnd | new value. |
Definition at line 153 of file tcp-validation.cc.
References g_validate, g_validationFailed, ns3::Time::GetSeconds(), ns3::Now(), ns3::Simulator::Now(), NS_LOG_WARN, and ns3::Time::S.
Referenced by ScheduleFirstTcpCwndTraceConnection().
void TraceFirstDctcp | ( | std::ofstream * | ofStream, |
uint32_t | bytesMarked, | ||
uint32_t | bytesAcked, | ||
double | alpha ) |
Trace first TcpDctcp.
ofStream | Output filestream. |
bytesMarked | Bytes marked. |
bytesAcked | Bytes ACKed. |
alpha | Alpha. |
Definition at line 199 of file tcp-validation.cc.
References g_validate, g_validationFailed, ns3::Time::GetSeconds(), ns3::Now(), ns3::Simulator::Now(), NS_LOG_WARN, and ns3::Time::S.
Referenced by ScheduleFirstDctcpTraceConnection().
Trace first RTT.
ofStream | Output filestream. |
oldRtt | Old value. |
newRtt | New value. |
Definition at line 251 of file tcp-validation.cc.
References g_validate, ns3::Time::GetSeconds(), and ns3::Simulator::Now().
Referenced by ScheduleFirstTcpRttTraceConnection().
Trace first Rx.
packet | The packet. |
address | The sender address. |
Definition at line 335 of file tcp-validation.cc.
References g_firstBytesReceived.
Referenced by ScheduleFirstPacketSinkConnection().
void TraceFirstThroughput | ( | std::ofstream * | ofStream, |
Time | throughputInterval ) |
Trace the first throughput.
ofStream | Output filestream. |
throughputInterval | The throughput interval. |
Definition at line 432 of file tcp-validation.cc.
References g_firstBytesReceived, g_validate, g_validationFailed, ns3::Time::GetSeconds(), ns3::Now(), ns3::Simulator::Now(), NS_LOG_WARN, ns3::Time::S, ns3::Simulator::Schedule(), throughput, and TraceFirstThroughput().
Referenced by TraceFirstThroughput().
void TraceMarksFrequency | ( | std::ofstream * | ofStream, |
Time | marksSamplingInterval ) |
Trace marks frequency.
ofStream | Output filestream. |
marksSamplingInterval | The mark sampling interval. |
Definition at line 412 of file tcp-validation.cc.
References g_marksObserved, g_validate, ns3::Time::GetSeconds(), ns3::Simulator::Now(), ns3::Simulator::Schedule(), and TraceMarksFrequency().
Referenced by TraceMarksFrequency().
void TracePingRtt | ( | std::ofstream * | ofStream, |
uint16_t | , | ||
Time | rtt ) |
Trace ping RTT.
ofStream | Output filestream. |
rtt | RTT value. |
Definition at line 320 of file tcp-validation.cc.
References g_validate, ns3::Time::GetSeconds(), and ns3::Simulator::Now().
void TraceQueueDrop | ( | std::ofstream * | ofStream, |
Ptr< const QueueDiscItem > | item ) |
Trace queue drop.
ofStream | Output filestream. |
item | The dropped QueueDiscItem. |
Definition at line 359 of file tcp-validation.cc.
References g_dropsObserved, g_validate, ns3::Time::GetSeconds(), and ns3::Simulator::Now().
void TraceQueueLength | ( | std::ofstream * | ofStream, |
DataRate | queueLinkRate, | ||
uint32_t | oldVal, | ||
uint32_t | newVal ) |
Trace queue length.
ofStream | Output filestream. |
queueLinkRate | Queue link rate. |
oldVal | Old value. |
newVal | New value. |
Definition at line 394 of file tcp-validation.cc.
References g_validate, ns3::DataRate::GetBitRate(), ns3::Time::GetSeconds(), and ns3::Simulator::Now().
void TraceQueueMark | ( | std::ofstream * | ofStream, |
Ptr< const QueueDiscItem > | item, | ||
const char * | reason ) |
Trace queue marks.
ofStream | Output filestream. |
item | The marked QueueDiscItem. |
reason | The reason. |
Definition at line 376 of file tcp-validation.cc.
References g_marksObserved, g_validate, ns3::Time::GetSeconds(), and ns3::Simulator::Now().
Trace second congestion window.
ofStream | Output filestream. |
oldCwnd | Old value. |
newCwnd | new value. |
Definition at line 268 of file tcp-validation.cc.
References g_validate, ns3::Time::GetSeconds(), and ns3::Simulator::Now().
Referenced by ScheduleSecondTcpCwndTraceConnection().
void TraceSecondDctcp | ( | std::ofstream * | ofStream, |
uint32_t | bytesMarked, | ||
uint32_t | bytesAcked, | ||
double | alpha ) |
Trace second TcpDctcp.
ofStream | Output filestream. |
bytesMarked | Bytes marked. |
bytesAcked | Bytes ACKed. |
alpha | Alpha. |
Definition at line 305 of file tcp-validation.cc.
References g_validate, ns3::Time::GetSeconds(), and ns3::Simulator::Now().
Referenced by ScheduleSecondDctcpTraceConnection().
Trace second RTT.
ofStream | Output filestream. |
oldRtt | Old value. |
newRtt | New value. |
Definition at line 287 of file tcp-validation.cc.
References g_validate, ns3::Time::GetSeconds(), and ns3::Simulator::Now().
Referenced by ScheduleSecondTcpRttTraceConnection().
Trace second Rx.
packet | The packet. |
address | The sender address. |
Definition at line 347 of file tcp-validation.cc.
References g_secondBytesReceived.
Referenced by ScheduleSecondPacketSinkConnection().
void TraceSecondThroughput | ( | std::ofstream * | ofStream, |
Time | throughputInterval ) |
Trace the second throughput.
ofStream | Output filestream. |
throughputInterval | The throughput interval. |
Definition at line 482 of file tcp-validation.cc.
References g_secondBytesReceived, g_validate, ns3::Time::GetSeconds(), ns3::Simulator::Now(), ns3::Simulator::Schedule(), and TraceSecondThroughput().
Referenced by TraceSecondThroughput().
uint32_t g_dropsObserved = 0 |
Number of dropped packets observed.
Definition at line 141 of file tcp-validation.cc.
Referenced by TraceQueueDrop().
uint32_t g_firstBytesReceived = 0 |
First received packet size.
Definition at line 138 of file tcp-validation.cc.
Referenced by TraceFirstRx(), and TraceFirstThroughput().
uint32_t g_marksObserved = 0 |
Number of marked packets observed.
Definition at line 140 of file tcp-validation.cc.
Referenced by TraceMarksFrequency(), and TraceQueueMark().
uint32_t g_secondBytesReceived = 0 |
Second received packet size.
Definition at line 139 of file tcp-validation.cc.
Referenced by TraceSecondRx(), and TraceSecondThroughput().
std::string g_validate = "" |
Empty string disables validation.
Definition at line 142 of file tcp-validation.cc.
Referenced by TraceFirstCwnd(), TraceFirstDctcp(), TraceFirstRtt(), TraceFirstThroughput(), TraceMarksFrequency(), TracePingRtt(), TraceQueueDrop(), TraceQueueLength(), TraceQueueMark(), TraceSecondCwnd(), TraceSecondDctcp(), TraceSecondRtt(), and TraceSecondThroughput().
bool g_validationFailed = false |
True if validation failed.
Definition at line 143 of file tcp-validation.cc.
Referenced by TraceFirstCwnd(), TraceFirstDctcp(), and TraceFirstThroughput().